river-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Michał Kłeczek <michal.klec...@xpro.biz>
Subject Re: SerialReflectionFactory and ObjectStreamContext
Date Mon, 10 Mar 2014 05:59:29 GMT
How about introducing a builder API:

public My getInstance(Arg1 arg1, ObjectInputStream ois, Arg2 arg2) {...}

public SerialReflectionFactory substitute() {
   return   SerialReflectionFactory.builder()
    .factory(My.class)
    .method("getInstance", ARG_TYPES)
    .param(p1)
    .streamParam()
    .param(p2)
    .build();
}

where "streamParam()" would indicate a placeholder for the actual input 
stream.

Thanks,
Michal

On Monday, March 10, 2014 10:48:29 AM Peter wrote:
> I'm open to suggestion.
> 
> Regards,
> 
> Peter.
> 
> ----- Original message -----
> 
> > Peter,
> > 
> > Can your SerialReflectionFactory expose an API to interact with the
> > stream? It   would be enough to be able to retrieve context Collection
> > from   ObjectStreamContext.
> > 
> > Thanks,
> 
> <Attachment>   Michał Kłeczek (XPro).vcf

-- 
Michał Kłeczek
XPro Sp. z o. o.
ul. Borowskiego 2
03-475 Warszawa
Polska

Mime
View raw message