input stringlengths 10 828 | output stringlengths 5 107 |
|---|---|
private jtext pane get jtext pane if j text pane warnings null j text pane warnings new jtext pane j text pane warnings set editable false j text pane warnings set background this get background return j text pane warnings | this method initializes j text pane |
private jtext field get jtext field if j text field drawer number null j text field drawer number new jtext field j text field drawer number set input verifier metadata retriever get input verifier specimen class drawer number j text field drawer number j text field drawer number set tool tip text metadata retriever get field help specimen class drawer number j text field drawer number add key listener new java awt event key adapter public void key typed java awt event key event e this pane set state to dirty return j text field drawer number | this method initializes j text field |
private jmenu item get jmenu item search if j menu item search null j menu item search new jmenu item j menu item search set text search j menu item search set enabled true j menu item search add action listener new java awt event action listener public void action performed java awt event action event e search dialog s new search dialog this main frame s set visible true return j menu item search | this method initializes j menu item6 |
private jtext field get jtext field4 if j text field verbatim locality null j text field verbatim locality new jtext field j text field verbatim locality set input verifier metadata retriever get input verifier specimen class verbatim locality j text field verbatim locality j text field verbatim locality set tool tip text metadata retriever get field help specimen class verbatim locality j text field verbatim locality add key listener new java awt event key adapter public void key typed java awt event key event e this pane set state to dirty return j text field verbatim locality | this method initializes j text field |
private jmenu item get jmenu item create labels if j menu item create labels null j menu item create labels new jmenu item j menu item create labels set text create unit tray labels j menu item create labels add action listener new java awt event action listener public void action performed java awt event action event e unit tray label browser lb new unit tray label browser lb pack lb set visible true return j menu item create labels | this method initializes j menu item create labels |
private jmenu item get jmenu item if j menu item stats null j menu item stats new jmenu item j menu item stats set text statistics j menu item stats add action listener new java awt event action listener public void action performed java awt event action event e specimen life cycle sls new specimen life cycle joption pane show message dialog singleton get singleton instance get main frame sls find specimen count record counts joption pane information message return j menu item stats | this method initializes j menu item |
private jtext field get jtext field13 if j text field country null j text field country new jtext field j text field country set input verifier metadata retriever get input verifier specimen class country j text field country j text field country set tool tip text metadata retriever get field help specimen class country j text field country add key listener new java awt event key adapter public void key typed java awt event key event e this pane set state to dirty return j text field country | this method initializes j text field1 |
private jtext field get jtext field23 if j text field primary division null j text field primary division new jtext field j text field primary division set input verifier metadata retriever get input verifier specimen class primary divison j text field primary division j text field primary division set tool tip text metadata retriever get field help specimen class primary divison j text field primary division add key listener new java awt event key adapter public void key typed java awt event key event e this pane set state to dirty return j text field primary division | this method initializes j text field2 |
private jtext field get jtext field24 if j text field tribe null j text field tribe new jtext field j text field tribe set input verifier metadata retriever get input verifier specimen class tribe j text field tribe j text field tribe set tool tip text metadata retriever get field help specimen class tribe j text field tribe add key listener new java awt event key adapter public void key typed java awt event key event e this pane set state to dirty return j text field tribe | this method initializes j text field2 |
private jcombo box get jcombo box sex if j combo box sex null j combo box sex new jcombo box sex get sex values j combo box sex set editable true j combo box sex set tool tip text metadata retriever get field help specimen class sex j combo box sex add key listener new java awt event key adapter public void key typed java awt event key event e this pane set state to dirty auto complete decorator decorate j combo box sex return j combo box sex | this method initializes j combo box sex |
private jcombo box get jcombo box features if j combo box features null j combo box features new jcombo box features get features values j combo box features set editable true j combo box features set tool tip text metadata retriever get field help specimen class features j combo box features add key listener new java awt event key adapter public void key typed java awt event key event e this pane set state to dirty auto complete decorator decorate j combo box features todo validate input length return j combo box features | this method initializes j combo box features |
private jcombo box get jcombo box life stage if j combo box life stage null j combo box life stage new jcombo box life stage get life stage values j combo box life stage set editable true j combo box life stage set tool tip text metadata retriever get field help specimen class lifestage j combo box life stage add key listener new java awt event key adapter public void key typed java awt event key event e this pane set state to dirty auto complete decorator decorate j combo box life stage return j combo box life stage | this method initializes j combo box life stage |
private jtext field get jtext field16 if j text field date emerged null j text field date emerged new jtext field 15 j text field date emerged set input verifier metadata retriever get input verifier specimen class date emerged j text field date emerged j text field date emerged set tool tip text metadata retriever get field help specimen class date emerged j text field date emerged add key listener new java awt event key adapter public void key typed java awt event key event e this pane set state to dirty return j text field date emerged | this method initializes j text field1 |
private jtext field get jtext field7 if j text field date collected null j text field date collected new jtext field 15 j text field date collected set tool tip text metadata retriever get field help specimen class date collected j text field date collected add key listener new java awt event key adapter public void key typed java awt event key event e this pane set state to dirty return j text field date collected | this method initializes j text field |
private jtext field get jtext field8 if j text field infraspecific epithet null j text field infraspecific epithet new jtext field 18 j text field infraspecific epithet set input verifier metadata retriever get input verifier specimen class infraspecific epithet j text field infraspecific epithet j text field infraspecific epithet set tool tip text metadata retriever get field help specimen class infraspecific epithet j text field infraspecific epithet add key listener new java awt event key adapter public void key typed java awt event key event e this pane set state to dirty return j text field infraspecific epithet | this method initializes j text field |
private jtext field get jtext field17 if j text field infraspecific rank null j text field infraspecific rank new jtext field 5 j text field infraspecific rank set input verifier metadata retriever get input verifier specimen class infraspecific rank j text field infraspecific rank j text field infraspecific rank set tool tip text metadata retriever get field help specimen class infraspecific rank j text field infraspecific rank add key listener new java awt event key adapter public void key typed java awt event key event e this pane set state to dirty return j text field infraspecific rank | this method initializes j text field1 |
private jtext field get jtext field authorship if j text field authorship null j text field authorship new jtext field j text field authorship set input verifier metadata retriever get input verifier specimen class authorship j text field authorship j text field authorship set tool tip text metadata retriever get field help specimen class authorship j text field authorship add key listener new java awt event key adapter public void key typed java awt event key event e this pane set state to dirty return j text field authorship | this method initializes j text field |
private jtext field get jtext field unnamed form if j text field unnamed form null j text field unnamed form new jtext field j text field unnamed form set input verifier metadata retriever get input verifier specimen class unnamed form j text field unnamed form j text field unnamed form set tool tip text metadata retriever get field help specimen class unnamed form j text field unnamed form add key listener new java awt event key adapter public void key typed java awt event key event e this pane set state to dirty return j text field unnamed form | this method initializes j text field1 |
private jtext field get jtext field11 if j text field verbatim elevation null j text field verbatim elevation new jtext field j text field verbatim elevation set input verifier metadata retriever get input verifier specimen class verbatim elevation j text field verbatim elevation j text field verbatim elevation set tool tip text metadata retriever get field help specimen class verbatim elevation j text field verbatim elevation add key listener new java awt event key adapter public void key typed java awt event key event e this pane set state to dirty return j text field verbatim elevation | this method initializes j text field |
private jtext field get jtext field19 if j text field collecting method null j text field collecting method new jtext field j text field collecting method set input verifier metadata retriever get input verifier specimen class collecting method j text field collecting method j text field collecting method set tool tip text metadata retriever get field help specimen class collecting method j text field collecting method add key listener new java awt event key adapter public void key typed java awt event key event e this pane set state to dirty return j text field collecting method | this method initializes j text field |
private jtext area get jtext area if j text area specimen notes null j text area specimen notes new jtext area j text area specimen notes set rows 3 j text area specimen notes set tool tip text metadata retriever get field help specimen class specimen notes j text area specimen notes add key listener new java awt event key adapter public void key typed java awt event key event e this pane set state to dirty return j text area specimen notes | this method initializes j text area |
private jtext field get jtext field20 if j text field questions null j text field questions new jtext field j text field questions set background main frame bg color qc field j text field questions set input verifier metadata retriever get input verifier specimen class questions j text field questions j text field questions set tool tip text metadata retriever get field help specimen class questions j text field questions add key listener new java awt event key adapter public void key typed java awt event key event e this pane set state to dirty return j text field questions | this method initializes j text field |
private jtext field get jtext field110 if j text field preparation type null j text field preparation type new jtext field j text field preparation type set input verifier metadata retriever get input verifier specimen class preparation type j text field preparation type j text field preparation type set tool tip text metadata retriever get field help specimen class preparation type j text field preparation type add key listener new java awt event key adapter public void key typed java awt event key event e this pane set state to dirty return j text field preparation type | this method initializes j text field1 |
private jtext field get jtext field26 if j text field associated taxon null j text field associated taxon new jtext field j text field associated taxon set input verifier metadata retriever get input verifier specimen class associated taxon j text field associated taxon j text field associated taxon set tool tip text metadata retriever get field help specimen class associated taxon j text field associated taxon add key listener new java awt event key adapter public void key typed java awt event key event e this pane set state to dirty return j text field associated taxon | this method initializes j text field2 |
private jtext field get jtext field34 if j text field habitat null j text field habitat new jtext field j text field habitat set input verifier metadata retriever get input verifier specimen class habitat j text field habitat j text field habitat set tool tip text metadata retriever get field help specimen class habitat j text field habitat add key listener new java awt event key adapter public void key typed java awt event key event e this pane set state to dirty return j text field habitat | this method initializes j text field3 |
private jcombo box get jcombo box if j combo box workflow status null j combo box workflow status new jcombo box work flow status get work flow status values j combo box workflow status set editable false j combo box workflow status set background main frame bg color qc field j combo box workflow status set tool tip text metadata retriever get field help specimen class workflow status auto complete decorator decorate j combo box workflow status return j combo box workflow status | this method initializes j combo box |
private jtext field get jtext field21 if j text field inferences null j text field inferences new jtext field j text field inferences set background main frame bg color ent field j text field inferences set input verifier metadata retriever get input verifier specimen class inferences j text field inferences j text field inferences set tool tip text metadata retriever get field help specimen class inferences j text field inferences add key listener new java awt event key adapter public void key typed java awt event key event e this pane set state to dirty return j text field inferences | this method initializes j text field |
private jtext field get jtext field10 if j text field isodate null j text field isodate new jtext field j text field isodate set input verifier metadata retriever get input verifier specimen class isodate j text field isodate j text field isodate set tool tip text metadata retriever get field help specimen class isodate j text field isodate add key listener new java awt event key adapter public void key typed java awt event key event e this pane set state to dirty return j text field isodate | this method initializes j text field |
private jbutton get jbutton12 if j button determinations null j button determinations new jbutton j button determinations set text dets j button determinations set mnemonic key event vk d j button determinations add action listener new java awt event action listener public void action performed java awt event action event e determination frame dets new determination frame specimen dets set visible true return j button determinations | this method initializes j button1 |
private jbutton get jbutton13 if j button1 null j button1 new jbutton j button1 set text date emerged j button1 add action listener new java awt event action listener public void action performed java awt event action event e if j text field date nos get text equals j text field date nos set text j text field date emerged get text else j text field date emerged set text j text field date nos get text return j button1 | this method initializes j button1 |
private jbutton get jbutton2 if j button2 null j button2 new jbutton j button2 set text date collected j button2 add action listener new java awt event action listener public void action performed java awt event action event e if j text field date nos get text equals j text field date nos set text j text field date collected get text else j text field date collected set text j text field date nos get text return j button2 | this method initializes j button2 |
private jbutton get jbutton specific locality if j button specific locality null j button specific locality new jbutton j button specific locality set text specific locality j button specific locality add action listener new java awt event action listener public void action performed java awt event action event e if j text field verbatim locality get text equals j text field verbatim locality set text j text field locality get text else j text field locality set text j text field verbatim locality get text return j button specific locality | this method initializes j button specific locality |
private jlabel get jtext field18 if j text field image count null j text field image count new jlabel number of images j text field date created set foreground color black return j text field image count | this method initializes j text field |
public table table table this name table get name this remarks table get remarks this schema table get schema this type table get type for iterator i table get columns iterator i has next this columns add column column i next for iterator i table get primary key attributes iterator i has next this primary key add i next | this objects copy constructor |
public void add primary key attribute string attribute primary key add attribute | adds an attribute to this code table code objects primary key |
public column get column string column for int i 0 i columns size i if column columns get i get name equals ignore case column return column columns get i return null | gets a code column code object with the specified name |
public column get column at int index return column columns get index | gets a code column code object from the code vector code of |
public void add schema schema schema schemas add schema | add the code schema code to this code catalog code |
public schema get schema string name for int i 0 i schemas size i if schema schemas get i get name equals name return schema schemas get i return null | get a code schema code contained within this code catalog code |
public list get column names array list column names new array list for int i 0 i columns size i column names add column columns get i get name return column names | get a code list code of column names for this table |
public boolean is nullable return nullable 0 | is this type nullable |
public boolean is unsigned return unsigned | is this numeric type unsigned |
public string get local type return local type name | get the localised version of the type name |
public int get min scale return int min scale | get the minimum scale of this numeric type |
public int get max scale return int max scale | get the maximum scale of this numeric type |
public void remove column string column name for int i 0 i columns size i if column columns get i get name equals ignore case column name columns remove i break | removes the code column code object with the specified name from this |
public string get prefix return literal prefix | get the prefix used to quote a literal |
public string get suffix return literal suffix | get the suffix used to quote a literal |
public object clone object object obj null try object obj column super clone catch clone not supported exception e this should never happen return object obj | clones this instance of the code column code class |
public string get catalog return table catalog | get the name of this columns catalog may be null |
public void set major version string version major version version | set the major version of this driver |
public void set minor version string version minor version version | set the minor version of this driver |
public void set archives file files paths new string files length for int i 0 i files length i try paths i files i get canonical path catch ioexception e ignore can t do much about an invalid file object | set the drivers |
public void set archive paths string paths this paths paths | set the drivers |
public string get database sql type return sql type name | get the database specific datatype of the column |
public boolean load from classpath return load from classpath | is this driver currently being loaded from the classpath |
public int get number of arguments required if decimal digits 1 return 2 else if size 1 return 1 else return 0 | get the number of arguments required by this type based on whether |
public int set document file f if f null throw new illegal argument exception null file init from file f return current state | set the document that this class should track |
public boolean is doc open return current state document editor doc open | convenience method that returns true if the current state is equal |
public boolean has unsaved changes return current state document editor doc changed | convenience method that returns true if the current state is equal |
public int get scale return decimal digits | get the scale of the numeric column |
public int save try buffered writer out new buffered writer new file writer file out write doc get text 0 doc get length 0 doc get length out flush out close current state document editor doc open catch exception e e print stack trace return current state | save the document and any outstanding changes |
public int save as file f if f null throw new illegal argument exception null file file f if file exists try file create new file catch ioexception e return save | save the document and any outstanding changes to a new file |
public int close doc null file null current state document editor doc closed return current state | stop editing the current document |
private void load document try buffered reader in new buffered reader new file reader file long length file length if length integer max value throw new unsupported operation exception big file int i integer parse int string value of length there is a better way of doing this string buffer buffer new string buffer i string str null while str in read line null buffer append str buffer append newline in close doc insert string 0 buffer to string null current state doc open catch exception e e print stack trace | read the file into the document |
private void document changed document event e current state document editor doc changed | the document has been changed |
public int show dialog guiutils show window this window parent return return value | show the dialog |
public short get type return sql data type | get the code java |
private void cache table metadata progress monitor progress cache table metadata supports schemas schema schemas values iterator next null progress | cache the table metadata |
public boolean is nullable if is nullable trim equals ignore case no return false else if nullable 1 return true else return true | is this column nullable |
private void populate drivers driver jcombo box set model jdbcdriver manager get combo box model | populate the driver combobox with all registered drivers |
private void cache column metadata progress monitor progress cache column metadata supports schemas schema schemas values iterator next null progress | cache the column metadata |
public string is nullable string return is nullable | get the nullable string where no means the column is definitely nullable |
private boolean save boolean result false if test user connection false false parameter means only show an alert or error box if there is a problem try new user connection user connection manager save new user connection user connection manager save all result true catch ioexception e new error box this could not save user connection e get message e true app get resources app get log error this e result false return result | save the user connection |
public int is nullable int return nullable | get the nullable int one of |
protected void list double clicked mouse event evt edit user connection action action performed guiutils to action event evt | jlist has been double clicked edit the selected user connection |
protected void list right clicked mouse event evt popup show evt get component evt get x evt get y | jlist has been right clicked show the popup menu |
private void close dialog this set visible false this dispose | close and dispose of the dialog |
private void cache product metadata progress monitor progress if progress null progress set max 2 progress set text retreiving product data try product name meta data get database product name if progress null progress increment product version meta data get database product version if progress null progress increment catch sqlexception e db2 dbapplication instance get log error this get class e | cache the product metadata |
protected void list clicked mouse event evt | jlist has been clicked once |
private void cache driver metadata progress monitor progress if progress null progress set text retreiving jdbc driver data progress set max 2 try driver name meta data get driver name if progress null progress increment driver version meta data get driver version if progress null progress increment catch sqlexception e db2 dbapplication instance get log error this get class e | cache the jdbc driver information |
private int start guessing int result column unknown unknown radix of 10 scale precision return result | try and guess the basic type of a column based on its attributes |
private void select right clicked item mouse event evt if j list null j list set selected index j list location to index new point evt get x evt get y | select the item in the jlist that was right clicked on not |
protected void list double clicked mouse event evt edit jdbcdriver action action performed guiutils to action event evt | jlist has been double clicked edit the selected driver |
public jscroll desktop pane get desktop return desktop | the global access point to the only code jscroll desktop pane code instance |
private void construct jpanel query builder jpanel new jpanel new flow layout flow layout left 0 5 auto commit jcheck box new jcheck box app get resources get string db2db gui preferences query builder auto commit app get preferences is query builder auto commit enabled auto commit jcheck box add action listener new action listener public void action performed action event evt query builder jpanel add auto commit jcheck box | construct the code jpanel code returned by code get jpanel code |
public void caret update caret event e mark dot abcdefghijklmnop dot e get dot mark e get mark if dot mark text is selected so enable cut and copy set enabled db2 dbactions cut action true set enabled db2 dbactions copy action true else set enabled db2 dbactions cut action false set enabled db2 dbactions copy action false | any text component that has selected text will cause the cut and copy |
public void table changed table model event evt changes made true | the only editable column the true false checkbox has changed |
private void add jbutton action action jbutton b new jbutton action b set text j tool bar add b | helper method to create a jbutton with the suppied action |
private jsplit pane create jsplit pane jsplit pane j split pane new jsplit pane jsplit pane horizontal split j split pane set divider size 6 return j split pane | helper method to create the main jsplit pane |
private jpanel create pallette jpanel jpanel j panel new jpanel stack layout new stack layout j panel return j panel | helper method to create the pallette jpanel layed out using stack layout |
private void remove pallette jpanel remove pallet jpanel from the jsplit pane j split pane remove pallette jpanel j split pane remove desktop jscroll pane jsplit pane not needed so remove this get content pane remove j split pane add desktop to jframe content pane this get content pane add desktop jscroll pane border layout center | remove the pallette panel from the application window user has |
private void add pallette jpanel remove the jscroll desktop pane desktop from the content pane this get content pane remove desktop jscroll pane set up the jsplit pane j split pane create jsplit pane pallette jpanel create pallette jpanel desktop jscroll pane new jscroll pane desktop j split pane set right component desktop jscroll pane j split pane set left component pallette jpanel this get content pane add j split pane border layout center | show the pallette panel user has requested a pallette when previously |
public string escape string s string escaped s if escaped index of 1 if identifier quote string null identifier quote string equals identifier quote string equals escaped identifier quote string escaped identifier quote string oh well i tried it s no use trying to escape with a null empty string or a space return escaped | escape the specified string using the identifier quote string returned by the driver |
public int show dialog guiutils show window this window app get main jframe return return value | show the dialog |
private void driver edited jdbcdriver driver if edited drivers null edited drivers new hashtable if edited drivers get driver get name null return driver already in there edited drivers put driver get name driver | a code jdbcdriver code has been edited |
public boolean supports min odbcsql return supports min odbcsql | does this database support minimum odbc sql grammer |
public boolean supports schemas return supports schemas | does this database support schemas |
public boolean supports core odbcsql return supports core odbcsql | does this database support core odbc sql grammer |
public void get connections connection name jcombo box set model user connection manager get combo box model | get a list of currently defined user connection |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.