input
stringlengths
10
828
output
stringlengths
5
107
public box get selection end return selection end
gets the selection end attribute of the context object
public int get selection start x return selection start x
gets the selection start x attribute of the context object
public int get selection end x return selection end x
gets the selection end x attribute of the context object
public void add handler action listener al if al instanceof action action al add property change listener enabled listener handlers add action listener class al
adds a delegate to this actionator
public void remove handler action listener al if al instanceof action action al remove property change listener enabled listener handlers remove action listener class al
removes the delegate action from this actionator
public string get command return string get value action action command key
gets the command string that will be sent to the
public void set command string command put value action action command key command
sets the command that will be passed to the delegate actions
public void action performed action event e logger fine recieved action event with command e get action command object h handlers get listener list for int i h length 2 i 0 i 2 action listener curr handler action listener h i 1 curr handler action performed e
passes the event to the delegate actions
public boolean is consumer return true
tests to see if this proxy consumes events
public void invoke prefs manager prefs resource def string value statement inserter def get property prefs inserts if inserter null resource trip inserter get resource resource pred trip get property rdf predicate get resource resource r model to add new model mem property p to add create property pred get uri if trip has property rdf subject r to add create resource trip get property rdf subject get resource else r to add create resource to add add r p value prefs change temporary null to add
it isnt clear at what layer these should be added
public model get added return added
gets all the rdf statements related to the query since the
public model get removed return removed
gets all of the rdf statements that were removed related to
public void invoke prefs manager prefs resource def string value try prefs get options manager print usage 10 catch preference exception e prefs get logger severe print usage failed e get localized message system exit 0
prints out usage information and exits the program
public extension filter string description string extensions this desc description this exts new hash set string for string ext extensions this exts add ext
creates a new filter for the given set of extensions
public boolean accept file f if f is directory return true string fname f get name to lower case int i fname last index of if i 1 fname fname substring i 1 return exts contains fname
tests to see if the file has an
public selector get selector return s
selects out a statement that is in the mru namespace
public void clean todo davidm remove old stuff from history
removes all older view entries from the file history
public void touch file string fname uri uri if fname starts with file uri uri create fname else uri new file fname to uri touch uri
touches the file at the given file path
public void invoke property triggers string prop val for iterator iter java props key set iterator iter has next prop string iter next val system get property prop if val null resource handler resource java props get prop trigger handler t try t find handler handler catch preference exception e1 throw new runtime exception e1 try t invoke prefs handler val catch rdfexception e throw new runtime exception model changed unexpectedly e
apply all the bound triggers to any matching system
protected void dispatch event awtevent event pre dispatch event super dispatch event event post dispatch event
overrides event queue
public prefs manager get prefs return prefs
gets the apploader preference manager
public object next if curr null no iterators throw new no such element exception object temp curr next last curr if curr has next while k internal length curr has next curr internal k k return temp
gets the next element in the flattened list of iterators
public void remove last remove
tries to call the appropriate remove method
public void set prefs prefs manager manager if prefs null prefs remove listener mru listener prefs manager reset if prefs null prefs add listener mru listener
sets the preference manager
public void set core app loader loader this loader loader
sets the associated limn3 core
public int get mrulength return mrulength
get the number of items to keep in the mru list
public void set mrulength int i if i mrulength mrulength i reset
sets the number of items to save in the mru list
public string get valid string return to string
gets a valid version from the current state
public void print usage throws preference exception print usage 1
prints the command line usage to the system error stream
public resource get action listener resource return action listener resource
the resource representing the open file bean this is used to set up
public void fire event table event e object l table listeners get listener list for int i l length 2 i 0 i 2 if l i table listener class table listener curr table listener l i 1 switch e get type case table event context click curr context click e break case table event main click curr click e break case table event alt click curr alt click e break case table event action click curr action click e break default throw new illegal argument exception not a click type e get type
fire the given event to all listeners
public void fire context click listenable table source int row int column int direction if table listeners get listener count 0 fire event new table event source table event context click row column direction
fire a context click to the table
public void fire click listenable table source int row int column int direction if table listeners get listener count 0 fire event new table event source table event main click row column direction
fire a context click to the table
public app loader get core return loader
gets the associated core bean
public resource get parent resource return parent resource
gets the resource representing the item usually an lal menu or an
public void fire alt click listenable table source int row int column int direction if table listeners get listener count 0 fire event new table event source table event alt click row column direction
fire an click to the table
public void fire action click listenable table source int row int column int direction if table listeners get listener count 0 fire event new table event source table event action click row column direction
fire an action click to the table
public iterator iterator list iter list new linked list iterator iter array for iterator cols l iterator cols has next collection c collection cols next iter list add c iterator iter array new iterator iter list size iter array iterator iter list to array iter array return new multi iterator iter array
iterate through all elements of the lists
public object get int i int count 0 iterator cols l iterator while count i cols has next collection curr collection cols next if i count curr size int local index i count if curr instanceof list return list curr get local index else iterator iter curr iterator while iter has next object n iter next if local index 0 return n count curr size throw new index out of bounds exception string value of i
finds the i i i th element in the flattened list
public int size int count 0 iterator cols l iterator while cols has next collection curr collection cols next count curr size return count
gets the sum of the sizes of the individual lists
public boolean is empty iterator cols l iterator while cols has next collection curr collection cols next if curr is empty return false return true
tests to see that all the component lists are empty
public void set parent resource resource resource parent resource resource reset
sets where in the menu the list should be attached
public void clear l clear
doesnt clear each list instead clears the list of
public list get inner list return l
gets the backing list
public void set inner list list l this l l
set the list backing this flattened list
public void remove trigger resource trigger throws preference exception trig names n trig names rlookup get trigger if n null loaded triggers remove trigger if n short name null short names remove n short name if n long name null long names remove n long name if n prop name null java props remove n prop name
removes the specified trigger
public void add prefix string prefix string uri prefix mapping system set ns prefix prefix uri prefix mapping user set ns prefix prefix uri prefix mapping temporary set ns prefix prefix uri prefix mapping file set ns prefix prefix uri
adds the given namespace short name prefix
public boolean on edge return direction center
detects if the click was slightly to the
public void add table listener table listener tl lta delegate add table listener tl
add a table listener
public void remove table listener table listener tl lta delegate remove table listener tl
removes the given table listener if it is among the ones attached
public void resize all columns to natural width for int i 0 i this get column count i resize column to natural width i
resizes all columns to the preferred width of their contents
public void set row height to maximum preferred height int pref height super get row margin 2 for int i 0 i this get row count i pref height math max pref height get natural height for row i this set row height pref height
sets the row heights to be the maximum preferred height
public void resize all rows to natural height for int i 0 i this get row count i resize row to natural height i
set the row heights to the maximum preferred height of each
public boolean check object o if o instanceof resource resource r resource o return r has property rdf type menu menu r has property rdf type menu item return false
checks that rdf resources are menu nodes
public int hash code return self null 0 self hash code
gets the hash code of the associated menu rdf resource
public print stream get original return original
gets the original stream
public boolean equals object o if this o return true else if o instanceof menu data node menu data node that menu data node o return null self null that self self equals that self else return false
true when the associated rdf nodes are equal
public string get presentation name if long name null object value try value prefs get core rdf node to value long name lue get client catch preference exception e1 prefs get logger warning e1 get localized message return short name if value instanceof list string buffer sb new string buffer for iterator e list value iterator e has next sb append string value of e next return sb to string else return value to string else return short name
get the presentation name for the undoable
public void resize column to natural width int col table column column get column model get column col int pref width get natural width for column column column set preferred width pref width last user set width for column put column new integer pref width
resizes the given column to the maximum preferred
public boolean is group return item null
tests to see if the node is a group
public void clear remove all object listeners explicit properties exp explicit properties get inner list get 0 exp clear get inner list clear get inner list add exp
removes all properties and listeners for changes to those
public void resize row to natural height int row int pref height get natural height for row row set row height row pref height
resizes the given row to the maximum preferred height
public boolean is item return item instanceof jmenu item item instanceof jmenu
tests to see if the node is a menu leaf an item
public void reset clear load describers
a harsher form of refresh this also changes the extensions
private enhanced table get table return enhanced table get viewport get view
get the table that is currently displayed
private undo table model get model return undo table model get table get model
get the table model that backs the action history pane
protected void reset children iterator ipls get inner list iterator get all the child instance property lists while ipls has next instance property list curr instance property list ipls next curr set object bean
resets all of the child property lists extended properties
public int get minimum natural column width return minimum natural column width
gets the minimum width that each column will be
protected void refresh children iterator ipls get inner list iterator get all the child instance property lists while ipls has next instance property list curr instance property list ipls next curr refresh
refreshes all of the child property lists extended properties
public void add action undoable edit e if cursor last save point last save point 1 if history size cursor int old size history size history sub list cursor history size clear get model fire table rows deleted cursor old size 1 history add e cursor history size get model fire table rows inserted cursor 1 cursor 1 clear to buffer
add a new action after the cursor
protected void just set object object o bean o
sets the instance object but assumes that it
public void set minimum natural column width int i minimum natural column width i
sets the minimum allowed width for auto resize
public void set object object o clear just set object o load describers
sets the object and resets the list of
public void action click table event e int go to e get row go to go to 0 0 history size go to history size 1 go to if cursor go to xxx if the user clicks a gray space make it white otherwise make the gray space white this makes the double click a toggle and avoids having to put a blank box at the end or a load file or save file box at the top this may prove too confusing go to 1 move cursor to go to
goes to the appropriate point in the action history
public string get column width description enumeration cols get column model get columns string buffer output new string buffer while cols has more elements table column tc table column cols next element column description cdesc new column description tc cdesc append to output output append return output to string
gets the description of the current set of widths and
public boolean equals object other if this other return true else if other instanceof my invocation handler return describer based properties this equals my invocation handler other outer else return false
true if the proxies are the same
public app loader get core return core
get the associated application launcher
public int hash code assert null this assert describer based properties this null return describer based properties this hash code
hash based on the outer class
public string to string return append to new string buffer to string
gets the string version of this description
public void set core app loader loader core loader
sets the associated application loader
public void parse in from string s parse in from string help debackslashed tokenizer s
parses a table column width description
private string get listener name resource olr string pname prefs get localized string olr props listener name return pname substring 0 1 to upper case pname substring 1
gets the name of the listener defined at the resource
public void undo if can undo move cursor to cursor 1
undo one action
public void change event model event event register menu reset event
resets the whole menu
public boolean can undo return cursor 0
tests to see if any undo events are available on the stack
public int apply this int col index column model get column index name if col index 0 column model get column col index set preferred width pref width return col index
applies the description to the current table
public void get extended properties for resource describer stmt iterator iter describer list properties props extended properties while iter has next resource ext resource iter next statement get resource object ext instance try ext instance prefs get core rdf node to value ext resource bean if ext instance instanceof instance property list get inner list add ext instance else logger warning error while loading extensions for bean bean n t from describer describer catch preference exception e logger warning error while loading extensions for bean bean n t from describer describer e print stack trace
gets all the extended properties associated
public void redo if can redo move cursor to cursor 1
redo one action
public boolean can redo return cursor history size
tests to see if any redo events are available above the stack
public void add listeners for resource describer stmt iterator iter describer list properties props add listener while iter has next resource r iter next statement get resource try add object listener r catch preference exception e logger severe error in config for property listener e get localized message
gets all the listeners types associated with the given
public void set column widths from description string description iterator st string help debackslashed tokenizer description table column model tcm get column model column description cd new column description int placed order 0 while st has next try cd parse in from st int col index cd apply this if col index 0 tcm move column col index placed order catch illegal argument exception iax
deserialize the column widths
public int get history cursor return cursor
get the location of the history cursor
protected void parse property describer resource describer get explicit properties for describer get extended properties for describer add listeners for describer
sets up the describer based properties using
public int get history size return history size
get the number of events currently stored in the history archive
public void add change listener change listener l change listeners add change listener class l
adds a listener for changes to the watched properties
public void remove change listener change listener l change listeners remove change listener class l
removes a listener for changes to the watched properties
public void property change property change event evt if enabled equals evt get property name boolean enabled boolean evt get new value boolean value iterator iter items key set iterator while iter has next jmenu item curr jmenu item iter next if curr null curr set enabled enabled return try reset menu core get root pane catch preference exception e prefs get logger log level warning unable to reset menu e
resets the whole menu or just the item if something small changed
public boolean has changed return get history cursor last save point
tests to see if the cursor is not at the last save point
public void set prefs prefs manager manager prefs manager if null prefs get object null reset
sets the application preferences associated with this
public void load user prefs throws preference exception if notifying listeners throw new illegal state exception model old user uri fname get user prefs file name if fname null boolean load false file nf new file fname if nf can read if user file null load true else load nf equals user file nf last modified user file date if load user file nf user file date user file last modified user new model mem help set prefs user fname synchronized this notifying listeners true reset prefs notifying listeners false notify model listeners old user
loads the user triplestore from an n3 file