input
stringlengths
10
828
output
stringlengths
5
107
public entity bean find entity bean entity bean bean object primary key throws ejbexception debug message first part called get abstract name for entity bean bean home find by primary key strings express primary key try entity bean cached bean get cached entity bean bean primary key debug message last part and found object in local cache return cached bean catch ejbexception failure return find response do command in transaction context new find command bean primary key this get result
the immediate action of this method is to load a single entity
public container get enclosing container return container
gets the container to which this bean object belongs
public entity bean get underlying bean iterator bean iterator joined beans values iterator collection underlying beans new vector while bean iterator has next underlying beans add bean wrapper bean iterator next get underlying bean return new thin siamese bean underlying beans orphaned fields key set orphaned fields values
gets the thin bean entity bean underlying this bean object
public void set underlying bean entity bean underlying bean collection underlying beans thin siamese bean underlying bean get beans iterator bean iterator underlying beans iterator joined beans new hashtable while bean iterator has next add entity bean entity bean bean iterator next
sets the thin siamese bean entity bean underlying this bean object
public object read resolve throws object stream exception container container container find local container application identifier object o container get bean object for entity bean container activate entity bean mr entity bean representation true false true true return o
returns a new client managed local object corresponding to the
public int compare object first object second int compare if first equals primary key getter return 1 if second equals primary key getter return 1 if first equals primary key setter return 1 if second equals primary key setter return 1 if first instanceof serializable method compare serializable method first get name compare to serializable method second get name else compare method first get name compare to method second get name if compare 0 compare first to string compare to second to string return compare
compares two bean methods
public boolean equals object other return other instanceof bean method comparator
compares two bean method comparators
private void add entity bean entity bean bean joined beans put bean get class container get bean object for entity bean bean cloned cloned
internal method to add a compoent bean to this siamese bean object
public entity bean find all of entity bean entity bean bean object primary key throws ejbexception debug message first part called get abstract name for entity bean bean home find all by primary key strings express primary key try entity bean cached bean get cached entity bean bean primary key debug message last part and found object in local cache return cached bean catch ejbexception failure return find response do command in transaction context new find command bean primary key true this get result
the immediate action of this method is to load a single entity
public collection auto add bean types throws ejbexception if joined beans size 0 throw new illegal state exception siamese bean has been manually populated else collection prototype beans new vector container process joined query joining query prototype beans new vector new mutable boolean false new mutable boolean false iterator bean iterator prototype beans iterator while bean iterator has next add entity bean entity bean bean iterator next return get bean objects
adds pooled beans to this siamese bean object based on the sql
public ejblocal object get bean object entity bean bean return ejblocal object joined beans get bean get class
extracts a component bean object from this siamese bean object
public comparable get primary key return primary key
returns the primary key of the bean this identifier refers to
public collection get bean objects return joined beans values
gets the bean objects comprising this siamese bean object
public void activate container container entity bean bean throws ejbexception java rmi remote exception bean ejb activate
called internally by the architecture in order
public entity context wrap container container ejblocal object bean this container container this bean bean this home container get home for bean object bean return this
amends an entity bean context to reflect a new
public object get bean object by table name string name return joined beans get container get type ignore case name get bean class
extracts a component bean object from this siamese bean object
public entity bean create entity bean immediately entity bean bean object primary key throws ejbexception create exception debug message first part called get abstract name for entity bean bean home create immediately strings express primary key try method throw on null key setter table get bean get class get abstract name for entity bean bean invoke bean new object primary key return bean catch invocation target exception bean failure throw new ejbexception exception thrown by primary key setter method bean failure catch illegal access exception bean failure throw new ejbexception primary key setter method of inappropriate access bean failure
the immediate action of this method is to create a single entity
public void add validate exception validate exception if exceptions null exceptions new vector exceptions add validate exception
adds a validate exception to this collection
public boolean has exception if exceptions null return false return exceptions is empty
returns true if this collection contains at least one validate exception
public bean object retrieve parent bean throws ejbexception finder exception if parent bean null return parent bean bean home context get ejblocal home find by primary key get parent primary key else return parent bean
a one to zero or one relationship destructor
public void put parent bean bean object parent bean throws ejbexception this parent bean parent bean set parent primary key parent bean get primary key
a one to zero or one relationship setter
public collection get orphaned field names return orphaned fields key set
returns the names of the orphaned fields in this siamese bean object
public object ejb create object primary key return primary key
callback before bean object creation
public void ejb post create object primary key
callback after bean object creation
public ejblocal home get ejblocal home throws ejbexception return null
gets the home interface implementation instance for this bean object
public collection select entity beans entity bean bean collection constrained fields throws ejbexception debug message first part called get abstract name for entity bean bean home find where fields equal constrained fields return select response do command in transaction context new select command bean constrained fields this get results
the immediate action of this method is to load many entity
public object get primary key throws ejbexception iterator bean iterator joined beans values iterator collection composite key new hash set while bean iterator has next composite key add ejblocal object bean iterator next get primary key return composite key
gets the primary key of this bean object
public void present ui print writer out frame layout layout uri context uri object bean int ui mode if output type equals markup xhtmlframeset xhtmlgenerator markup generator new xhtmlgenerator get uiservlet uri get charset get language markup generator open frameset new sgmlwriter out ui mode markup generator present frameset layout markup generator close else present page out layout context uri bean ui mode
presents the current ui updated menu options and current
public void load throws ejbexception iterator bean iterator joined beans values iterator collection commands new vector while bean iterator has next commands add new load command bean wrapper bean iterator next get underlying bean cloned false iterator response iterator container do commands commands iterator while response iterator has next response response response response iterator next if response instanceof load response add entity bean load response response get result else if response instanceof purge response container uncache beans purge response response get begin sequence no purge response response get identifiers
loads business objects from persistent storage into this
public collection select all of entity beans entity bean bean collection constrained fields throws ejbexception debug message first part called get abstract name for entity bean bean home find all where fields equal constrained fields return select response do command in transaction context new select command bean constrained fields true this get results
the immediate action of this method is to load many entity
public void strip abstract bean source file throws ioexception string line mutable integer in code new mutable integer 0 mutable integer max depth this method new mutable integer 0 mutable boolean in initializer new mutable boolean false mutable boolean in slash star new mutable boolean false mutable boolean in class comment new mutable boolean false while line strings obfuscate coded read line in code max depth this method in initializer in slash star in class comment throw new unsupported operation exception not implemented false null writer println line system out println line
strips the source file obtained via this reader and sends
public void close throws ioexception super close writer close
closes the reader and the writer
public void load sister throws ejbexception load throw new sister exception no sisters
instructs the bean object to synchronize with persistent storage
public void write closed source file write abstract sequence new string tokenizer close source get string source file message null
output the evaluation of the source file abstract key
protected void write key string key char end char if key ends with write compound concrete key key substring 0 key length 1 else if character is digit end char key char at key length 1 indent level new integer new character end char to string int value statement indentation on this block false in slash star new mutable boolean false write abstract sequence new string tokenizer close source get string key else message key write concrete sequence close source get string key
writes the evaluation of a concrete or abstract key
public void store throws ejbexception iterator bean iterator joined beans values iterator while bean iterator has next client managed local object bean object client managed local object bean iterator next container store entity bean bean wrapper bean object get underlying bean bean object is cloned bean object is shallow cloned false
stores business objects in persistent storage
public local home get home throw new ejbexception home not instantiated in deployment container
get the home interface implementation instance for this bean type
protected void write repeated section string tokenizer section string initial token string current token list tokens new vector message if initial token null tokens add initial token while current token ends with section has more tokens current token section next token equals if current token ends with tokens add strings strip suffix current token
writes a section bounded by curly braces as many times
public void store with related throws ejbexception iterator bean iterator joined beans values iterator boolean local transaction container get status status status no transaction try if local transaction container begin while bean iterator has next client managed local object bean iterator next store with related if local transaction container commit catch ejbexception bean failure try if local transaction container rollback catch illegal state exception rollback failure throw bean failure catch exception other failure try if local transaction container rollback catch illegal state exception rollback failure throw new ejbexception other failure
stores business objects in persistent storage along with related objects
public collection select entity beans in order entity bean bean collection constrained fields string order field name throws ejbexception if order field name null debug message first part called get abstract name for entity bean bean home find where fields equal constrained fields else debug message first part called get abstract name for entity bean bean home find in order field name order constrained fields return select response do command in transaction context new select command bean constrained fields order field name false this get results
the immediate action of this method is to load many entity
public void present page print writer out frame layout layout uri context uri object bean int ui mode assert bean null stand back to back with your foe concrete markup generator markup generator create concrete markup generator out context uri ui mode count out loud together taking a pace for each count markup generator present page layout bean turn and fire markup generator close
presents the current ui page to the client in preparation
public boolean is dirty throws no such object local exception iterator bean iterator joined beans values iterator while bean iterator has next if client managed local object bean iterator next is dirty return true return false
checks whether any of these beans have been changed since they were last
protected void write compound concrete key string key message key try string prefix while true for char index a index z index write concrete sequence close source get string key prefix new character index prefix roll prefix catch missing resource exception missing key
writes a compound concrete key which is indicated
public boolean is dummy throws no such object local exception iterator bean iterator joined beans values iterator while bean iterator has next if client managed local object bean iterator next is dummy return true return false
indicates that this bean is a placeholder and can never be
private string roll string prefix if prefix length 0 prefix a else int roll index prefix length 1 while roll index 1 if prefix char at roll index z simple roll prefix prefix substring 0 roll index new character char prefix char at roll index 1 prefix substring roll index 1 prefix length roll index 1 finished else iterative roll prefix prefix substring 0 roll index a prefix substring roll index 1 prefix length if roll index 1 prefix a prefix return prefix
rolls forward a spreadsheet style column identifier
public void present menu bar print writer out frame layout layout uri context uri collection menu options assert menu options null stand back to back with your foe concrete markup generator markup generator create concrete markup generator out context uri ui view only count out loud together taking a pace for each count markup generator present menu bar layout menu options turn and fire markup generator close
presents the current top level menu options to the client
public collection select all of entity beans in order entity bean bean collection constrained fields string order field name throws ejbexception if order field name null debug message first part called get abstract name for entity bean bean home find all where fields equal constrained fields else debug message first part called get abstract name for entity bean bean home find all in order field name order constrained fields return select response do command in transaction context new select command bean constrained fields order field name true this get results
the immediate action of this method is to load many entity
protected void write concrete sequence string line define locals line pre escape line line true for int index 0 index indent level index print if line starts with print line escape line line true try message format formatter new message format line println formatter format line concrete key parameters catch illegal argument exception substitution failure throw new illegal argument exception substitution failure get message line
writes the evaluation of a concrete key sequence
public boolean is persistent throws no such object local exception iterator bean iterator joined beans values iterator while bean iterator has next if client managed local object bean iterator next is persistent return false return true
checks whether any of these beans do not have a persistent copy
private boolean define locals iterator parameter iterator map current key parameter map pair 1 key set iterator while parameter iterator has next integer parameter index integer parameter iterator next object parameter value map current key parameter map pair 1 get parameter index if parameter value instanceof collection concrete key parameters parameter index int value parameter value return true
called when an abstract key is met which defines
private string pre escape line string line boolean process indentation if line starts with line line substring 1 line length
ensures that curly braces appearing in the source
public void make dirty throws no such object local exception iterator bean iterator joined beans values iterator while bean iterator has next client managed local object bean iterator next make dirty
flags that this bean is not synchronized with persistent storage
private string escape line string line boolean process indentation if line starts with line line substring 0 3 strings image line substring 3 else line strings image line
ensures that curly braces appearing in the source
public collection select siamese bean objects string sql query join response response debug message first part called container select siamese bean objects sql query response join response do command in transaction context new join command sql query this return bundle thin siamese bean into siamese bean object collection response get results response get query
the immediate action of this method is to load many entity
public void present menu strip print writer out frame layout layout uri context uri menu option selected menu option assert selected menu option null stand back to back with your foe concrete markup generator markup generator create concrete markup generator out context uri ui view only count out loud together taking a pace for each count markup generator present menu strip layout selected menu option turn and fire markup generator close
presents the currently selected submenu options to the
public void make dummy throws no such object local exception iterator bean iterator joined beans values iterator while bean iterator has next client managed local object bean iterator next make dummy
flags that this bean object is a placeholder for data only
private object message object o debugging is switched off if o null system out println else system out print o to string return o
prints a debug message or not if debugging
public list get types try return list methods get parameter types on longest 0 catch null pointer exception x if superclass reader null return superclass reader get types else throw new ejbexception find where fields equal method not found in home
get the parameter types of the longest find where fields equal method
public list bundle entity bean collection into entity bean list collection entity beans throws ejbexception if entity beans instanceof list return list entity beans else return new vector entity beans
internal utility method to take a collection of thin entity beans
public list get names try return list methods get parameter types on longest 1 catch null pointer exception x if superclass reader null return superclass reader get names else throw new ejbexception find where fields equal method not found in home
get the formal parameter names of the longest find where fields equal method
public list get types or empty list if none try return list methods get parameter types on longest 0 catch null pointer exception x if superclass reader null return superclass reader get types or empty list if none else return new vector
get the parameter types of the longest find where fields equal method
public boolean are relatives persistent throws no such object local exception iterator bean iterator joined beans values iterator while bean iterator has next if client managed local object bean iterator next are relatives persistent return false return true
checks the direct and indirect relationships to determine whether they
public set bundle entity bean collection into entity bean set collection entity beans throws ejbexception if entity beans instanceof set return set entity beans else return new hash set entity beans
internal utility method to take a collection of thin entity beans
public list get names or empty list if none try return list methods get parameter types on longest 1 catch null pointer exception x if superclass reader null return superclass reader get names or empty list if none else return new vector
get the formal parameter names of the longest find where fields equal method
public list get types class parameter types try list list new vector for int i 0 i parameter types length i list add dequalify parameter types i get name return list methods get list 0 catch null pointer exception x if superclass reader null return superclass reader get types else throw new ejbexception find where fields equal method not found in home
get the parameter types of the specified find where fields equal method
public entity bean load entity bean entity bean bean throws ejbexception debug message first part called get object idfor entity bean bean load return load response do command in transaction context new load command bean this get result
the immediate action of this method is to refresh an entity
public list get names class parameter types try list list new vector for int i 0 i parameter types length i list add dequalify parameter types i get name return list methods get list 1 catch null pointer exception x if superclass reader null return superclass reader get names else throw new ejbexception find where fields equal method not found in home
get the formal parameter names of the specified find where fields equal
public map bundle bean object collection into bean object map collection bean objects throws ejbexception map map new hash map bean objects size iterator bean objects iterator bean objects iterator while bean objects iterator has next ejblocal object bean object ejblocal object bean objects iterator next object primary key bean object get primary key map put primary key bean object return map
internal utility method to take a collection of bean objects
public list get import targets return import targets
get the targets referenced in the import clauses
public object invoke on server method method object parameters throws ejbexception throw new ejbexception not supported for siamese beans
execute a method of this bean objects underlying entity bean
public void close throws ioexception super close if superclass reader null superclass reader close
closes both this reader and any
private string dequalify string qualified name return dequalify qualified name false return methods dequalify qualified name
takes the package name off a class name
private string dequalify string qualified name boolean strip nullable qualified name strings after last qualified name if strip nullable qualified name starts with nullable return strings strip prefix qualified name nullable else return qualified name
takes the package name off a class name
public void auto start daemons if daemon support iterator auto start daemon list iterator auto start daemon list iterator while auto start daemon list iterator has next do start command string auto start daemon list iterator next auto start daemon list clear
starts daemons which have been scheduled to be automatically started
public set bundle entity bean list into primary key set list entity beans throws ejbexception return bundle entity bean collection into primary key set entity beans
internal utility method to take a list of thin entity beans
public void remove throws ejbexception remove exception iterator bean iterator joined beans values iterator joined beans new hashtable while bean iterator has next client managed local object bean object client managed local object bean iterator next container remove entity bean bean wrapper bean object get underlying bean bean object is cloned bean object is shallow
removes business objects from persistent storage
public server daemon add daemon string name server daemon daemon return add daemon name daemon false
adds a recognised daemon to this container and initializes it through its
protected load response do load command connection database connection statement statement string buffer query load command command entity bean bean throws sqlexception message loaded get idfor entity bean bean return null
directly executes a load command
public server daemon add daemon string name server daemon daemon boolean auto start if daemon support debug message adding recognised daemon name daemon table put name daemon daemon init name this if auto start auto start daemon list add name return daemon
adds a recognised daemon to this container initializes it through its
protected store response do store command connection database connection statement statement string buffer query set changed classes entity bean bean throws sqlexception message stored get idfor entity bean bean return null
directly executes a store command
public start response start daemon string name throws ejbexception debug message first part called daemon container start daemon name return start response do command in transaction context new start command name
starts a daemon running on the server by calling its start method
public set bundle entity bean set into primary key set set entity beans throws ejbexception return bundle entity bean set into primary key set entity beans
internal utility method to take a set of thin entity beans
public entity bean activate entity bean entity bean bean throws ejbexception return activate entity bean mr entity bean bean true true
the immediate action of this method is to reactivate a bean
protected remove response do remove command connection database connection statement statement string buffer query set changed classes entity bean bean throws sqlexception message removed get idfor entity bean bean return null
directly executes a remove command
public stop response stop daemon string name throws ejbexception debug message first part called daemon container stop daemon name return stop response do command in transaction context new stop command name
stops a daemon running on the server by calling its stop method
protected invoke response do invoke command invoke command command entity bean bean throws invocation target exception illegal access exception object key get key getter for entity bean bean invoke bean null if key null message invoked get abstract name for entity bean bean home invoke command command get method get name else message invoked get abstract name for entity bean bean key invoke command command get method get name return null
directly executes an invoke command
public start response do start command string name if daemon support server daemon daemon if daemon table contains key name daemon server daemon daemon table get name start synchronized running daemon list running daemon list add daemon message started daemon name else throw new ejbexception no daemon named name return new start response
start a local daemon by calling its start method
public stop response do stop command string name if daemon support server daemon daemon if daemon table contains key name daemon server daemon daemon table get name stop synchronized running daemon list running daemon list remove daemon message signalled running daemon name to stop else throw new ejbexception no daemon named name return new stop response
stop a local daemon by calling its stop method
protected log response do log command log command command message command get log message return new log response
directly executes a log command
protected flush response do flush command entity bean bean message flushed get abstract name for entity bean bean s from local caches return null
directly executes a flush command
public collection bundle entity bean into bean object collection collection entity beans throws ejbexception return bundle entity bean into bean object collection entity beans false
internal utility method to take a collection of thin entity beans
public void end atom
called by a server daemon to indicate that it has completed processing an
public void shutdown if daemon support iterator daemon iterator running daemon list iterator server daemon daemon while daemon iterator has next daemon server daemon daemon iterator next stop message signalled running daemon daemon get name to stop daemon iterator daemon table values iterator while daemon iterator has next daemon server daemon daemon iterator next message destroying daemon daemon get name daemon destroy super shutdown
terminates all running daemons by calling stop then finalizes
public collection bundle entity bean into bean object collection collection entity beans boolean as clones throws ejbexception collection bean objects new vector entity beans size iterator entity beans iterator entity beans iterator while entity beans iterator has next bean objects add get bean object for entity bean entity bean entity beans iterator next as clones as clones return bean objects
internal utility method to take a collection of thin entity beans
public map restore unrelated return new hash map
restores business objects which have been explicitly unrelated from
public entity bean activate entity bean entity bean bean boolean recurse throws ejbexception return activate entity bean mr entity bean bean recurse true
the immediate action of this method is to reactivate a bean
public list bundle entity bean into bean object list list entity beans throws ejbexception return list bundle entity bean into bean object collection entity beans
internal utility method to take a list of thin entity beans
protected map build field name getter method table entity bean bean return build field name getter method table bean get class
internal utility method to make a map from the field names to the
public void unrelate all in flat map map relationship unrelated table throws ejbexception
does a bulk removal of business objects from relationships
public list bundle entity bean into bean object list list entity beans boolean as clones throws ejbexception return list bundle entity bean into bean object collection entity beans as clones
internal utility method to take a list of thin entity beans