|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object FlkDemo
public class FlkDemo
FlkDemo contains methods to maintain the DB/FlkDemoDB.txt database used by Flicker. The file is a tab-delimited file with the following 7 fields: SubMenuName, SubMenuEntry, ClickableURL1, ImageURL1, ClickableURL2,ImageURL2,StartupData
The map is used to build menus of images to load a map entry contains the following fields: 1. SubMenuName: is the menu image name: e.g., "Human Plasma" 2. SubMenuEntry: is the menu image name: e.g., "(Swiss2DPAGE vs Merril) gels - clickable" 3. ClickableURL1: is the clickable map URL for image 1: e.g., "http://www.expasy.org/cgi-bin/map3/big/PLASMA_HUMAN?" 4. ImageURL1: is the Image URL for image 1: e.g. "http://www.expasy.org/ch2dgifs/PLASMA_HUMAN/PLASMA_HUMAN_id.gif" 5. ClickableURL2: is the clickable map URL for image 2: e.g., "" 6. ImageURL2: is the Image URL for image 2: e.g. "plasmaL.gif" 7. StartupData: is TRUE if should be the default startup for Flicker. "TRUE" The database file DB/FlkDemoDB.txt contains data Fields: SubMenuName, SubMenuEntry, ClickableURL1, ImageURL1, ClickableURL2,ImageURL2,StartupData E.g. of a data entry: Human Plasma (Swiss2DPAGE vs Merril) gels - clickable http://www.expasy.org/cgi-bin/map3/PLASMA_HUMAN? PLASMA_HUMAN_id.gifplasmaL.gif FALSE
This work was produced by Peter Lemkin of the National Cancer Institute, an agency of the United States Government. As a work of the United States Government there is no associated copyright. It is offered as open source software under the Mozilla Public License (version 1.1) subject to the limitations noted in the accompanying LEGAL file. This notice must be included with the code. The Flicker Mozilla and Legal files are available on http://open2dprot.sourceforge.net/Flicker
Field Summary | |
---|---|
(package private) java.lang.String |
clickableURL1
ClickableURL1: is the clickable map URL for image 1: e.g., "http://www.expasy.org/cgi-bin/map3/big/PLASMA_HUMAN?" |
(package private) java.lang.String |
clickableURL2
ClickableURL2: is the clickable map URL for image 2: e.g., "" |
private static Flicker |
flk
Instance of Flicker |
static java.lang.String |
FlkDemoDBfile
name of the database file |
static FlkDemo[] |
flkDemos
FlkDemo database [0:nMaps] |
(package private) java.lang.String |
imageURL1
ImageURL1: is the Image URL for image 1: e.g. |
(package private) java.lang.String |
imageURL2
imageURL2: is the Image URL for image 2: e.g. |
static int |
MAX_DATABASES
MAX # of demo databases |
static int |
MAX_DEMOS
Max # of demo images |
static int |
nMaps
# of FlkDemos[] map entries |
(package private) boolean |
startupDataFlag
is TRUE if should be the default startup for Flicker. |
(package private) java.lang.String |
subMenuEntry
is the menu image name: e.g., "(Swiss2DPAGE vs Merril) gels - clickable" |
(package private) java.lang.String |
subMenuName
is the menu image name: e.g., "Human Plasma" |
private static Util |
util
Instance of Util |
Constructor Summary | |
---|---|
FlkDemo(Flicker flkS)
FlkDemo() - constructor for Class FlkDemo |
|
FlkDemo(java.lang.String subMenuName,
java.lang.String subMenuEntry,
java.lang.String clickableURL1,
java.lang.String imageURL1,
java.lang.String clickableURL2,
java.lang.String imageURL2,
java.lang.String startupData)
FlkDemo() - constructor to add a new FlkDemo entry NOTE: to do add of an entry, use 'new FlkDemo()' method |
Method Summary | |
---|---|
static void |
clear()
clear() - clear database flkDemos[0:nMaps-1]. |
boolean |
delete()
delete() - rmv entry from database flkDemos[0:nMaps-1]. |
static int |
lookup(FlkDemo fm)
lookup() - lookup entry to database flkDemos[0:nMaps-1]. |
static int |
lookupByFileName(java.lang.String fileName1,
java.lang.String fileName2)
lookupByFileName() - lookup entry by file name to flkDemos[0:nMaps-1]. |
(package private) static int |
lookupBySubmenu(java.lang.String subMenuEntry)
lookupBySubmenu() - lookup entry by submenu name to flkDemos[0:nMaps-1]. |
(package private) static int |
lookupBySubMenuNameAndEntry(java.lang.String subMenuName,
java.lang.String subMenuEntry)
lookupBySubMenuNameAndEntry() - lookup entry by matching BOTH the SubMenuName and SubMenuEntry in the flkDemos[0:nMaps-1]. |
static boolean |
parseAndAddEntry(java.lang.String flkDemoDBdata)
parseAndAddEntry() - parse and add entry to global to flkDemos[0:nMaps-1] if the data is well formed. |
private static boolean |
read()
read() - read database from FlkDemoDB.txt file to flkDemos[0:nMaps-1]. |
boolean |
set(java.lang.String subMenuName,
java.lang.String subMenuEntry,
java.lang.String clickableURL1,
java.lang.String imageURL1,
java.lang.String clickableURL2,
java.lang.String imageURL2,
boolean startupDataFlag)
set() - set entry to database flkDemos[0:nMaps-1]. |
static boolean |
write()
write() - write database in memory to DB/FlkDemoDB.txt database file. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
private static Flicker flk
private static Util util
public static final int MAX_DEMOS
public static final int MAX_DATABASES
public static FlkDemo[] flkDemos
public static int nMaps
public static java.lang.String FlkDemoDBfile
java.lang.String subMenuName
java.lang.String subMenuEntry
java.lang.String clickableURL1
java.lang.String imageURL1
java.lang.String clickableURL2
java.lang.String imageURL2
boolean startupDataFlag
Constructor Detail |
---|
public FlkDemo(Flicker flkS)
flk
- instance of Flickerpublic FlkDemo(java.lang.String subMenuName, java.lang.String subMenuEntry, java.lang.String clickableURL1, java.lang.String imageURL1, java.lang.String clickableURL2, java.lang.String imageURL2, java.lang.String startupData)
subMenuName
- subMenuEntry
- clickableURL1
- imageURL1
- clickableURL2
- imageURL2
- startupData
- Method Detail |
---|
private static boolean read()
public static boolean parseAndAddEntry(java.lang.String flkDemoDBdata)
flkDemoDBdata
- is a text file tab-delimited \n row terminated
set of data for parsing into the FlkDemo[] database table.
public static boolean write()
public static int lookup(FlkDemo fm)
fm
- is the instance to lookup
static int lookupBySubmenu(java.lang.String subMenuEntry)
subMenuEntry
- is the menu name of the instance to lookup
static int lookupBySubMenuNameAndEntry(java.lang.String subMenuName, java.lang.String subMenuEntry)
subMenuName
- is the menu name of the instance to lookupsubMenuEntry
- is the menu name of the instance to lookup
public static int lookupByFileName(java.lang.String fileName1, java.lang.String fileName2)
fileName1
- is the fileName name of the instance to lookup
for imageURL1 (if not null)fileName2
- is the fileName name of the instance to lookup
for imageURL2 (if not null)
public boolean set(java.lang.String subMenuName, java.lang.String subMenuEntry, java.lang.String clickableURL1, java.lang.String imageURL1, java.lang.String clickableURL2, java.lang.String imageURL2, boolean startupDataFlag)
subMenuName
- subMenuEntry
- clickableURL1
- imageURL1
- clickableURL2
- imageURL2
- startupData
-
public boolean delete()
public static void clear()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |