input
stringlengths 10
828
| output
stringlengths 5
107
|
|---|---|
public boolean contains declaration declaration element some invocation for iterator i actual set iterator i has next declaration element de declaration element i next if de equals signature some invocation return true return false
|
checks according to signature
|
public void add declarations deset key collection of declaration elements actual set add all collection of declaration elements actual set
|
add a collection of declaration elements
|
public boolean contains declaration declaration element element return actual set contains element
|
checks according to key
|
public boolean contains declarations deset key elements return actual set contains all elements actual set
|
checks if this set contains the given set
|
public void remove declarations deset key elements actual set remove all elements actual set
|
removes declarations from this set
|
public iterator de iterator return actual set iterator
|
returns an iterator
|
public boolean is empty return actual set is empty
|
true if empty
|
public collection to collection return actual set
|
returns this set as a collection
|
public string to string line wrapped if actual set size 0 return no elements empty set string buffer result new string buffer first element iterator i actual set iterator result append i next other elements while i has next declaration element d declaration element i next result append n d return result to string
|
returns a representative string of the members of the deset
|
public boolean contains declaration once string name int count 0 for iterator i actual set iterator i has next declaration element e declaration element i next if e contains declaration once name count if count 1 return true return false
|
checks whether the declaration with the given simple name
|
public declaration element get declaration with simple name string name for iterator i actual set iterator i has next declaration element e declaration element i next if e contains declaration once name return e return null
|
returns all the declaration elements with the given simple name
|
public declaration element get declaration element of binding ibinding binding for iterator i actual set iterator i has next declaration element current de declaration element i next if current de has key binding get key return current de return null
|
return the declaration element which contains this binding
|
public boolean is infer type2 executable return is itexecutable
|
returns whether the refactoring infer type is executable
|
public boolean start creates new wizard wizard new graphical infer type wizard set project wizard init platform ui get workbench null instantiates the wizard container with the wizard and opens it wizard dialog dialog new wizard dialog shell wizard dialog create dialog set block on open true starts the code manipulation return dialog open wizard dialog ok
|
start the wizard
|
public void schedule declaration element declaration element e throws code change exception if e instanceof single declaration element ilog log ilog log manipulate 2 handling single de handle declaration element single declaration element e else ilog log ilog log manipulate 2 handling composite de handle composite declaration element composite declaration element e
|
schedules a declaration element to be re declared
|
private void handle composite declaration element composite declaration element de throws code change exception for iterator i de get declaration elements de iterator i has next handle declaration element single declaration element i next
|
perform actions on composites
|
public boolean visit array creation node if de get kind declaration element class de get kind declaration element interface if de has key node resolve type binding get key this node node return true
|
array find the array creation node
|
public void add new dedeclaration declaration element de new declarations add de
|
schedule a declaration element
|
public boolean visit class instance creation node if node null return true ilog log ilog log ast 4 visiting class instance creation node to string note that in anonymous instance creations the resolve constructor binding method will return the constructor of the anonymous type which does not really exist not legal imethod binding the constructor null if node get anonymous class declaration null the constructor anon workaround get super constructor binding node resolve constructor binding else the constructor node resolve constructor binding treat invocation the constructor node arguments return true
|
visiting class instance creations
|
private boolean is valid type itype binding declared type itype binding type to check declared type array check for is valid type must use element type if declared type is array type to check declared type get element type return valid types contains type to check type to check get qualified name equals java lang object declared type is array
|
checks if the given type is a valid one
|
protected boolean is valid string the package string the simple name try if used names contains the simple name return false if java project find type the package the simple name null return false return true catch java model exception e return false
|
this method checks whether the new type name is a valid one
|
protected void find illegal deaccesses declaration element declaration element if declaration element get transitive invocations null return for iterator i declaration element get transitive invocations de iterator i has next declaration element current invoc declaration element i next check methods if current invoc get kind declaration element method int modifier current invoc get modifiers check for static method if modifier is static modifier static methods add declaration current invoc check for nonpublic method if modifier is public modifier nonpublic methods add declaration current invoc check fields if current invoc get kind declaration element field fields add declaration current invoc
|
this methods evaluates the transitive invocations of the declaration element
|
private single declaration element get selected declaration element itext selection text icompilation unit icu throws internal calculation exception use a visitor to extract the binding of the method or variable util itypes u new util itypes compilation unit cu u parse compilation unit icu true compilation unit visitor vis new compilation unit visitor text cu accept vis if vis get declaration element null throw new internal calculation exception infer type not a valid selection n you must select a reference field parameter local variable or method where it is declared return vis get declaration element
|
this method determines the selected declaration element
|
private type element get equal existing type deset signature methods if methods size 0 type element object hset get all types get type element java lang object return object type element existing type null for iterator iter hset get all types type iterator iter has next type element current type type element iter next if current type get all members equals methods if existing type null existing type get all super types contains current type existing type current type return existing type
|
this methods checks whether an equal type already exists
|
public void deploy string resource throws ioexception input stream in loader get resource as stream resource if in null throw new ioexception resource resource not found if resource ends with zip deploy new zip input stream in else if resource ends with sss deploy resource in else throw new ioexception unsupported file type resource
|
supports a single
|
public void scrape object session map string string cookiejar throws scrape exception this scrape session cookiejar null
|
kicks off the scrape using the given annotated session object
|
public string get session id object source if source null source get class is annotation present scrape session class return source get class get annotation scrape session class name return null
|
returns the session id for an annotated
|
public void add error int code string raw text errors put code raw text
|
add an error to the exception
|
private object run script string script object session map string string cookiejar log debug string format running script n s n script binding binding new binding binding set variable cookiejar cookiejar binding set variable session session groovy shell shell new groovy shell binding object result shell evaluate script log debug script result result return result
|
executes the script located within the lt test gt lt test gt tags
|
public math container get parent return parent
|
gets parent of this component
|
public int get parent index if parent null return 0 for int i 0 i parent size i if parent get argument i this return i this should not happen return 0
|
gets index of this comonent within its parent component
|
public math sequence get parent return math sequence super get parent
|
gets parent of this component
|
public int get up index int n return meta get up index n
|
up index for n th argument
|
public int get down index int n return meta get down index n
|
down index for n th argument
|
public string get argument type int n return meta get parameter n get type
|
argument type for n th argument
|
public void set argument int i int j math sequence argument set argument i columns j argument
|
sets i th row j th column cell
|
public math sequence get argument int i int j return get argument i columns j
|
returns i th row j th column cell
|
public int first formula strange but correct return next formula 1
|
get index of first formula
|
public int last formula return prev formula element list null element list size 0
|
get index of last formula
|
public boolean has next formula int current for int i current 1 i element list null element list size 0 i if get element i instanceof math formula return true return false
|
is there a next formula
|
public void copy int ioffset int joffset math array array for int i 0 i rows joffset i array rows i for int j 0 j columns ioffset j array columns j math sequence component array get argument i j component math sequence component clone formula set argument i ioffset j joffset component
|
copy array into this object with silent clipping
|
public int next formula int current for int i current 1 i element list null element list size 0 i if get element i instanceof math formula return i throw new array index out of bounds exception index out of array bounds
|
get index of next formula
|
public boolean has prev formula int current for int i current 1 i 0 i if get element i instanceof math formula return true return false
|
is there previous formula
|
public int prev formula int current for int i current 1 i 0 i if get element i instanceof math formula return i throw new array index out of bounds exception index out of array bounds
|
get index of previous formula
|
public math model get model return model
|
gets math model for this formula
|
public int get model index if model null return 0 for int i 0 i model size i if model get element i this return i this should not happen return 0
|
gets index of this formula within math model
|
public math component get argument int i return arguments null arguments get i null
|
returns ith argument
|
public void set argument int i math component argument if arguments null arguments new array list math component i 1 if argument null argument set parent this arguments set i argument formula set modified true
|
sets ith argument
|
public int size return arguments null arguments size 0
|
returns number of arguments
|
public int first strange but correct return next 1
|
get index of first argument
|
public int last return prev arguments null arguments size 0
|
get index of last argument
|
public boolean has next int current for int i current 1 i arguments null arguments size 0 i if get argument i instanceof math container return true return false
|
is there a next argument
|
public int next int current for int i current 1 i arguments null arguments size 0 i if get argument i instanceof math container return i throw new array index out of bounds exception index out of array bounds
|
get index of next argument
|
public boolean has prev int current for int i current 1 i 0 i if get argument i instanceof math container return true return false
|
is there previous argument
|
public int prev int current for int i current 1 i 0 i if get argument i instanceof math container return i throw new array index out of bounds exception index out of array bounds
|
get index of previous argument
|
public boolean has children for int i 0 i arguments null arguments size 0 i if get argument i instanceof math container return true return false
|
are there any arguments
|
public boolean has operator for int i 0 i size i if is operator i return true else if get argument i instanceof math function equals math function get argument i get name return true return false
|
has operator including power
|
public boolean is script int i return i 0 i size get argument i instanceof math function equals math function get argument i get name equals math function get argument i get name
|
is ith argument script
|
public boolean is character int i return i 0 i size get argument i instanceof math character math character get argument i is character
|
is ith argument character
|
public boolean is operator int i return i 0 i size get argument i instanceof math character math character get argument i is operator
|
is ith argument operator
|
private void add element int i object element if element instanceof math formula add formula i math formula element else if element instanceof string add label i string element
|
add element override to add new type
|
public int size return arguments length
|
number of arguments
|
public int get up index int n return arguments n get up index
|
up index for n th argument
|
public int get down index int n return arguments n get down index
|
down index for n th argument
|
public void next character if current offset current field size current field get argument current offset null current field get argument current offset instanceof math container math container current field get argument current offset has children math component component current field get argument current offset first field math container component else if current offset current field size current offset else next field
|
next character key
|
public void prev character if current offset 1 0 current field get argument current offset 1 null current field get argument current offset 1 instanceof math container math container current field get argument current offset 1 has children math component component current field get argument current offset 1 last field math container component else if current offset 0 current offset else prev field
|
previous character key
|
public void first field math container component formula get root component first field component
|
select first field
|
public void last field math container component formula get root component last field component
|
select last field
|
public meta function get general string name return meta function get component general name
|
get custom function
|
public void prev field prev field current field
|
find previous field
|
public void new function string name new function name 0
|
insert function by name
|
public specie get specie return this specie
|
getter of the species
|
public void set specie specie specie this specie specie
|
setter of the specie
|
public void set first reading is done boolean first reading is done this first reading is done first reading is done
|
setter of the boolean which informs if the first reading is done
|
public boolean is first reading is done return first reading is done
|
getter of the boolean which informs if the first reading is done
|
public void set first reading is ok boolean first reading is ok this first reading is ok first reading is ok
|
setter of the boolean which informs if the first reading is ok
|
public boolean is first reading is ok return first reading is ok
|
getter of the boolean which informs if the first reading is done
|
public void set second reading is done boolean second reading is done this second reading is done second reading is done
|
setter of the boolean which informs if the second reading is done
|
public boolean is second reading is done return second reading is done
|
getter of the boolean which informs if the second reading is done
|
public void set second reading is ok boolean second reading is ok this second reading is ok second reading is ok
|
setter of the boolean which informs if the second reading is ok
|
public boolean is second reading is ok return second reading is ok
|
getter of the boolean which informs if the second reading is ok
|
public void set accepted boolean value accepted value
|
setter of the boolean which informs if the analysis is accepted
|
public void set list result vector results list result this list result list result
|
setter of the list of results
|
public type analysis get type return type
|
getter of the type of the analysis
|
public void set type type analysis type this type type
|
setter of the type of the analysis
|
public void set species specie species this species species
|
setter of the species of the animal
|
public specie get species return species
|
getter of the species of the animal
|
public void validate first reading boolean bool this set first reading is done true this set first reading is ok bool
|
permits to perform the first reading on the analysis
|
public void validate second reading boolean bool if this is first reading is ok this set second reading is done true this set second reading is ok bool
|
permits to perform the second reading on the analysis
|
public void set batch batch batch this batch batch
|
the setter of the batch
|
public void validate analysis boolean bool if this is second reading is ok this set accepted bool
|
permits to validate the analysis or not
|
public int get num order return this num order
|
the getter of the number of the order
|
public void set num order int num order this num order num order
|
the setter of the number or the order
|
public type analysis get type analysis return type analysis
|
getter of the batch type of analysis
|
public void set type analysis type analysis type analysis this type analysis type analysis
|
setter of the batch type of analysis
|
public type sample get type sample return type sample
|
getter of the batch samples type
|
public void set type sample type sample type sample this type sample type sample
|
setter of the batch samples type
|
public boolean add sample sample sample boolean added false if this get type sample equals sample get type this get type analysis equals sample get analysis get type this get list sample add sample added true return added
|
permits to add a sample in the batch
|
public void edit info string login string password string email bouml preserved body begin 0001 f48 e this email email this login login this password password bouml preserved body end 0001 f48 e
|
permits to modify the customers login info
|
public boolean equals object it boolean bool true if this login equals internet services it get login bool false else if this password equals internet services it get password bool false else if this email equals internet services it get email bool false return bool
|
redefinition of the equals method
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.