input
stringlengths
10
828
output
stringlengths
5
107
public string get event description return description
retrieves the descriptive message for this flow event
public boolean is empty if channel peek null return true else return false
checks to see if the monitor is empty
public flow command event take throws interrupted exception return flow command event channel take
take an event from the monitor
public void put flow command event event try channel put event start catch interrupted exception ex try once more try channel put event start catch interrupted exception ex1
deposit a report for a task
protected void fire task event task event task event final task event final task event task event for iterator i task event listeners iterator i has next final task event listener task event listener task event listener i next thread thread new thread public void run task event listener process event final task event t...
utility method for subclasses to call in order to
public task state message take throws interrupted exception return task state message channel take
take an event from the monitor
public void put task state message report try channel put report handler signal catch interrupted exception ex try once more try channel put report handler signal catch interrupted exception ex1
deposit a report for a task
public string get state string return state machine get current state get state string
retrieves a string representation of the state for this task
public int get first part id iterator itor m part list iterator part part part itor next if part null return 1 else return part get id
convenience method for pulling out the id of the first part
public boolean flow should be cleaned return should be cleaned
checks to see if this flow is ready for release
public part get part by name string name part ret null iterator itor m part list iterator while itor has next part part part itor next if name equals part get name ret part break return ret
convenience method for fetching a part by the value of its name property
public void add service point service point sp if sps null sps new array list sps add sp
adds a service point to the result set
public service point get service point int index return service point sps get index
retrieves a service point for a given index
public void notify graph node change check all parents to see if ready to fire if is ready for dispatch dispatch
checks to see if ready to dispatch by checking parents
public service point get service point string desc throws no matching service point exception service point req null try iterator iterator sps iterator while iterator has next req null service point current service point iterator next if current get description equals desc req current catch exception ex throw new no ma...
get a service point by description if no matching
private void cancel children graph node chd get children for int i 0 i chd length i task tsk task chd i if tsk get current state task state cancelled tsk get current state task state failed tsk get current state task state complete tsk process task message new task state message tsk get parent flow get id tsk get id ta...
cancels all child tasks
public void set workflow status int workflow status m workflow status workflow status
one of complete running prerun failed
private void toggle turret throws interrupted exception turret tracking system toggle turret if turret tracking system turret online status label set text idle else status label set text set turret on off label
turns turret online offline
public boolean set status label string text if turret tracking system turret online status label set text text return true else return false
method for external components to change the status label of the main interface
public string get annoucement string is session int index throws exception if index 0 index session get user is session get announcements size return session get user is session get announcements get index get announcement id throw new exception ndice inv lido
recupera o announcement
public string find profile by interests string interest return find profile interest interest replace
search a profile by interest
public string find profile by gender string gender return find profile gender gender replace
search a profile by gender
public int get number all sub blogs string blog id return get all sub blogs blog id size
return a number of a
public int get number of comments string login string blog id session int comments 0 try blog if blog find blog id blog id session get 0 for post post blog get post manager get posts for comment coment post get comment manager get comments comments post get number of all sub comments coment get id 1 catch exception e s...
get number of comments
public string find profile by name string name return find find profile by name name
search a profile by name
public string find profile by interests string interest return find find profile by interests interest
search a profile by interest
public post search post by id string id list blog if all blogs get all blogs for blog if blog all blogs for post post blog get post manager get posts if post get id equals id return post return null
search a post by id
public string find blog by name string name list blog if blogs find find blog title name string impressao for int i 0 i blogs size i impressao blogs get i get id if i blogs size 1 impressao return impressao
find blog by name
public blog if find blog by id string id return find find blog by id id
find a blog by id
public int get number all sub blogs string blog id return find get number all sub blogs blog id
get a number of all sub blogs
public int get number of comments string login string blog id session return find get number of comments login blog id session
get number of comments
private void initialize post string title throws exception if is valid string title throw new exception t tulo obrigat rio
initialization of the post
private boolean is valid string string to check if to check null to check trim is empty return false return true
verify if it is a valid string
public boolean set id session string id session throws exception if id session matches 0 9 return set property user blog flags post idsession id session else throw new exception sess o inv lida
sets the id session of the blog
public boolean set title string title return set property user blog flags post title title
sets the title of the blog
public boolean set description string description return set property user blog flags post description description
sets the description of the blog
public properties get properties return blog
return the properties list of the this blog
public string get super blog return sub blog get property user blog flags post owner get flag
returns the title of the super blog
public void set super blog blog super blog throws exception if super blog null sub blog set property owner super blog get properties get property user blog flags post title get flag else throw new exception super blog cannot be null
sets the superblog if it has one
public properties get properties return sub blog
return the properties list of the this sub blog
public boolean set birth date string birth date throws exception todo it must verify a lots of things should it become a class string date birth date split try gregorian calendar data new gregorian calendar data set lenient false data set gregorian calendar year integer parse int date 2 data set gregorian calendar mont...
update the birth date of this user
public boolean set gender string gender throws ioexception invalid property exception list string list genders new array list string list genders add masculino list genders add feminino list genders add n o informado if is valid string gender throw new invalid property exception sexo inv lido if list genders contains g...
update the gender of this user
public boolean set email string email throws exception passwd database manager pdm passwd database manager get instance properties p pdm get passwd if email null throw new exception email inv lido if email trim equals throw new exception email inv lido if p contains value email throw new exception email existente if ch...
update the e mail of this user
private boolean check email string email final string at int at position email index of at if at position 0 at position email length return false string kjf email split at if kjf length 2 kjf 0 trim is empty return false return true
verify if an e mail is valid
private boolean set property flags flag string content if profile contains key flag get flag if content null fixme one more thing to fix the shit the i did content profile set property flag get flag content return true return false
update a flag with the gave value
private boolean is valid profile properties profile string flags flags get flags for string flag flags if profile contains key flag return false return true
this method verify if a
private boolean check string string to check int max size if is valid string to check return false if to check length max size return false return true
this method check if a
private string find in cache flags flag string atribute iterator profile it cache iterator clear search recent if cache is empty while it has next profile profile it next try if profile get personal property flag contains atribute search recent add profile catch exception ex return to string
find a profile in cache
public void set user string uid throws invalid info exception if is valid string uid throw new invalid info exception please choose a valid uid this uid uid
set the informations to be manipulated to this uid
public boolean is user password string password throws encripting exception string encripted password passwords get property uid return encripted password equals encript password
verify if a password is the password of this uid
private string encript string word throws encripting exception cipher cipher try cipher cipher get instance algorithm cipher init cipher encrypt mode secret key parameter specified return encoder encode cipher do final word get bytes catch exception e throw new encripting exception some thing nasty occurred while encri...
this method is responsible for encrypting the password
private void load passwords throws invalid properties format exception ioexception try prepare files prepare file path file input stream in new file input stream path passwords new properties passwords load from xml in in close catch invalid properties format exception e throw new invalid properties format exception yo...
this method load all the password in shadow
public boolean remove password string password throws encripting exception if is user password password passwords remove uid return true return false
remove a password of the shadow
public boolean force remove password if passwords contains key uid passwords remove uid return true return false
remove a password without check the password
private boolean is valid string string to check if to check null return false char charateres to check to char array for char character charateres if character return true return false
this method verify if a code string code is valid
public void create try buffered reader in new buffered reader new input stream reader get class get resource as stream database sql utf 8 string builder cmd new string builder string line while line in read line null cmd append line if line contains execute command new procedure cmd to string override public void with ...
constructs all the tables necessary for a tsumego database
public sgfnode parse throws ioexception return parse game tree
parses the first sgf game tree in a collection
private void eat char expected throws ioexception char c read if expected c throw new parser exception expected expected got c line offset
removes the given character from the buffer
private boolean try eat char expected throws ioexception char c peek if expected c read return true else return false
attempts to remove the given character from the buffer
private boolean peek char expected throws ioexception char c peek return expected c
returns true if the next character in the buffer is the
public match player player1 player player2 player white black int handicap int komi if player1 get parsed rating float value player2 get parsed rating float value white player1 black player2 else white player2 black player1 handicap int white get parsed rating float value black get parsed rating float value if handicap...
pairs two players and uses their rating to generate the handicap and
private void refresh if match table get selected row count 0 unpair button set enabled true else unpair button set enabled false if unpaired table get selected row count 1 autopair button set text autopair selected autopair button set enabled true else if unpaired table get selected row count 0 autopair button set enab...
sets button label and status
public void set minimum int new minimum min new minimum
sets the minimum value
public void add card t card if decks is empty throw new illegal state exception no decks decks get 0 add card
adds the given card to the first deck
public void promote t card int deck number get deck number card int new deck number deck number 1 if new deck number decks size already in the last deck new deck number deck number decks get deck number remove card decks get new deck number add card
promotes the given card to the next deck i
public void demote t card int deck number get deck number card int new deck number if deck number 0 new deck number 0 else already in the first deck new deck number deck number 1 decks get deck number remove card decks get new deck number add card
demotes the given card to the previous deck i
public void add batch collection t batch this unseen batches add new linked list t batch
adds a new batch of cards to this quiz engine
public mdcadapter get mdca return new log4j mdcadapter
currently this method always returns an instance of
public void put string key string val org apache log4j mdc put key val
put a context value the code val code parameter as identified with
public void promote t card if open unseen cards contains card open unseen cards remove card deck manager add card card deck manager promote card else if open leitner cards contains card open leitner cards remove card deck manager promote card else throw new illegal argument exception card card was not retrieved from th...
promotes the given card to the next leitner deck
public void demote t card if open unseen cards contains card open unseen cards remove card deck manager add card card else if open leitner cards contains card open leitner cards remove card deck manager demote card else throw new illegal argument exception card card was not retrieved from the get cards method
demotes the given card to the previous leitner deck
private matcher matcher string pattern string input if input null input return pattern compile pattern matcher input
returns the matcher for the given pattern
public game get game throws interrupted exception return null
blocks until put game is called
public void on module load check logged in and respond fill headline date
this is the entry point method
public boolean rule applies attributes input attributes return input attributes equals node attribute
this function determines whether the input attributes given matches
public boolean rule applies collection input attributes return input attributes contains node attribute
this function determines whether the any input attributes of the list given matches
public string next token throws no such element exception return m string current index
function that will return the next string token
public boolean has more tokens if current index m string length return true else return false
determines whether a next string token is available
public int count tokens return m string length current index
returns the number of tokens
public int disambiguate list word tokens before simple word token focus token list word tokens after throws sentence disambiguator exception check focus token focus token collection relevant attributes get relevant attributes word tokens before word tokens after po sdecision tree pos decision tree get po sdecision tree...
this function disambiguates sentence boundaries of the focus token
public void reset m current index 0 m initial index 0
resets the indexes that are used to get the corpus words
public string to list by tt slds study level service get dtos bds skjl service get bjxx by tutor skjl get tutor return success
tutor or teacher
public void base statistics xml throws exception result get data result this write result to response xml helper parse base vos result base vo
flashchart xml br
public user get current user return current user user session get constants current login erp successful user
session current user current fzx dto
public string list this week all this seach for this week schedule return success
list action method
public string list next week all this seach for next week schedule return success
list next action method
public string update xyfl try xyxx service update xyfl xyxx opt success catch exception e e print stack trace opt failure return success
for cash br
public string to list for ec rds user service get user dtos by role role role edu tutor get current fzx dto init xyjbs init kclbs xyxx xyxx service get xyxx return success
for ec ec
public string to list tjxy xyxx set create start date utils get today morning xyxx set create end date utils get tomorrow morning init sexes init lflxs return success
for cc cc
public string to query for qt ryzp set mssj start new date ryzp set mssj end new date return success
to for qt
public string get html return get element get inner html
returns the html if it is set to html
public void set html string html get element set inner html html
sets the label value to be the specified html
public void clear finder cache list map clear
clear the finder cache
public void clear cache list map clear pojo map clear
clear both the finder cache and pojo cache
public void add result string url long result list map put url result
add results to list map cache
protected string select encoding return this encoding
select an appropriate character encoding to be used based on the
public void rs int sql type not null string key nullable string value throws jsonexception key key if value null null out else if sql type bigint sql type integer sql type double out print value else out print if sql type char out print value else new jsontokener value stream out out print
writes normal values from resultset to printwriter in a json style
public void escaped not null string key nullable string value throws jsonexception key key if value null null out else out print new jsontokener value stream out out print
prints escaped and quoted like key value
public void expired start response status expired ordinal response end
the client is not logged in
public void reset logger parent l log info attempting to reset the connection from 0 parent get name in transaction false last system current time millis if close statement st close try st database factory statement schema catch connect exception e l log severe failed to reset e
a final resort method that closes the statement and connection