public class PhantomCBar extends Object implements IReloadable
| Modifier and Type | Field and Description |
|---|---|
Vector<PhantomCBarControl> |
barControls
The bar controls
|
FileChangedChecker |
configuration
The configuration data
|
String |
fileName
The file name of the BAR (not including .PHB file extension), or null if
in-memory.
|
static int |
FLAG_BITMAP
Bar control bitmap type
|
static int |
FLAG_BMPBUTTON
Bar control bitmap button type
|
static int |
FLAG_CAPSLOCK_SUBTYPE |
static int |
FLAG_CUSTOMDT_SUBTYPE |
static int |
FLAG_DATETIME
Bar control date time type and subtypes
|
static int |
FLAG_HOSTFLD_TYPE
Bar control hostfield type
|
static int |
FLAG_INSERT_SUBTYPE |
static int |
FLAG_KBDIND_TYPE
Bar control keyboard indicator type and subtypes
|
static int |
FLAG_LARROW_SUBTYPE |
static int |
FLAG_LDATE_SUBTYPE |
static int |
FLAG_LTIME_SUBTYPE |
static int |
FLAG_MSG_TYPE
Bar control message type
|
static int |
FLAG_NUMLOCK_SUBTYPE |
static int |
FLAG_QUESTION_SUBTYPE |
static int |
FLAG_RARROW_SUBTYPE |
static int |
FLAG_SCRLOCK_SUBTYPE |
static int |
FLAG_SDATE_SUBTYPE |
static int |
FLAG_SPACING
Bar control spacing type
|
static int |
FLAG_STDBUTTON
Bar control standard button type and subtypes
|
static int |
FLAG_STIME_SUBTYPE |
static int |
FLAG_TEXT_TYPE
Bar control text type
|
static int |
FLAG_USERDRAW
Bar control user draw type
|
static int |
globalFileIndex
New property global file name index.
|
boolean |
isTemplate
The flag that indicates if this instance is saved in templatefile
or in a PhantomPanel.
|
FAILURE, NOTHING_DONE, SUCCESS| Constructor and Description |
|---|
PhantomCBar()
Empty constructor for dynamic load.
|
PhantomCBar(PhantomControl bd,
PhantomFile data,
String newFilename)
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
static PhantomCBar |
createPhantomBar(PhantomControl bd,
PhantomCUserWindow uw,
PhantomFile data)
This method returns a bar object if it's already loaded
or loads it from file.
|
PhantomCBarControl |
getBarControl(String label)
Methods that returns the bar control with the specified
argument label, which is either the label of the object
or the index to the object
|
Vector<PhantomCBarControl> |
getBarControls()
Returns the bar controls
|
PhantomCBarControl |
getControlWithLabel(String label)
Method that returns the bar control object specified by the label argument
Called from fetchBarControl
|
int |
getCreateFlags()
Returns the create flags
|
int |
getFontSize()
Returns the font size
|
PhantomHostField |
getHostField(String hostFieldName)
Returns the host field or null if bar is template.
|
PhantomObject |
getObject(String objectName,
String referer)
Returns the object or null if bar is template.
|
int |
getRefSaveSize()
Get the size when reference is saved to file.
|
int |
getSaveSize()
Get the size.
|
void |
load(PhantomControl bd,
PhantomFile data,
String newFilename)
Creates an instance of the control class.
|
boolean |
needsReload()
Check if this file needs to be reloaded.
|
int |
reload(boolean force)
Reload internal state from external sources.
|
void |
save(PhantomOutputFile file)
Saves the instance of the control class to file.
|
void |
save(String namedFile)
Saves the bar to a named file.
|
void |
saveRef(PhantomOutputFile file)
This method saves the bar object to file.
|
public FileChangedChecker configuration
public Vector<PhantomCBarControl> barControls
public String fileName
public boolean isTemplate
public static final int FLAG_MSG_TYPE
public static final int FLAG_TEXT_TYPE
public static final int FLAG_HOSTFLD_TYPE
public static final int FLAG_KBDIND_TYPE
public static final int FLAG_CAPSLOCK_SUBTYPE
public static final int FLAG_NUMLOCK_SUBTYPE
public static final int FLAG_SCRLOCK_SUBTYPE
public static final int FLAG_INSERT_SUBTYPE
public static final int FLAG_DATETIME
public static final int FLAG_STIME_SUBTYPE
public static final int FLAG_LTIME_SUBTYPE
public static final int FLAG_SDATE_SUBTYPE
public static final int FLAG_LDATE_SUBTYPE
public static final int FLAG_CUSTOMDT_SUBTYPE
public static final int FLAG_STDBUTTON
public static final int FLAG_LARROW_SUBTYPE
public static final int FLAG_RARROW_SUBTYPE
public static final int FLAG_QUESTION_SUBTYPE
public static final int FLAG_BMPBUTTON
public static final int FLAG_BITMAP
public static final int FLAG_USERDRAW
public static final int FLAG_SPACING
public static int globalFileIndex
public PhantomCBar(PhantomControl bd, PhantomFile data, String newFilename) throws IOException
IOExceptionpublic PhantomCBar()
public void load(PhantomControl bd, PhantomFile data, String newFilename) throws IOException
Read:
Header information
+ Signature BYTE [3]
+ Version BYTE
+ Size of description USHORT
+ Size of data USHORT
+ Filler (for WIN16) USHORT
+ Description [Size of description]
Bar information
+ Bar data size USHORT
Bar data
+ Create flags ULONG
+ Dirty LONG
+ Country code LONG
+ Country index LONG
+ Rectangle for bar RECTL [8 x ULONG]
+ Font PSZ
+ Font size LONG
+ Max no of characters in Caps LONG
+ Max no of characters in Num LONG
+ Max no of characters in Scrl LONG
+ Max no of characters in Ins LONG
+ Min width for chars in dynamic controls LONG
+ Min dyn LONG
+ System border Width/Height LONG
+ System border Width/Height * 2 LONG
+ System border Width/Height * 3 LONG
+ System border Width/Height * 8 LONG
+ System border Width/Height * 9 LONG
+ Bar height LONG
+ Char ? LONG
+ Font used in status bar ULONG
+ Handle to user window ULONG
+ First keyboard indicator (-1 if none) SHORT
+ First host connected field (-1 if none) SHORT
+ First date time field (-1 if none) LONG
+ Field for keyboard hook LONG
+ Number of bar controls LONG
+ Bar controls PBAR_CTL
+ Id of user window BYTE [16]
+ Bar object call on create and destroy BYTE [9]
Font information
+ Font size USHORT
+ Font name [Size of font name]
Bar control information
+ Bar control data size USHORT
Bar control data
+ Rectangle for bar control RECTL [8 x ULONG]
+ Width LONG
+ Width in pixels LONG
+ Type of control LONG
+ Sub type of control LONG
+ Control flags ULONG
+ Object ID PSZ
+ Label of control PSZ
+ Control dependent text PSZ
+ Help ID (Only buttons) PSZ
+ Current text contents BYTE [81]
+ State (Control dependent usage) LONG
+ Data (Control dependent usage) PVOID
IOException - if an I/O error occurs.public void save(String namedFile) throws IOException
namedFile - IOExceptionpublic void save(PhantomOutputFile file) throws IOException
Read:
Header information
+ Signature BYTE [3]
+ Version BYTE
+ Size of description USHORT
+ Size of data USHORT
+ Filler (for WIN16) USHORT
+ Description [Size of description]
Bar information
+ Bar data size USHORT
Bar data
+ Create flags ULONG
+ Dirty LONG
+ Country code LONG
+ Country index LONG
+ Rectangle for bar RECTL [8 x ULONG]
+ Font PSZ
+ Font size LONG
+ Max no of characters in Caps LONG
+ Max no of characters in Num LONG
+ Max no of characters in Scrl LONG
+ Max no of characters in Ins LONG
+ Min width for chars in dynamic controls LONG
+ Min dyn LONG
+ System border Width/Height LONG
+ System border Width/Height * 2 LONG
+ System border Width/Height * 3 LONG
+ System border Width/Height * 8 LONG
+ System border Width/Height * 9 LONG
+ Bar height LONG
+ Char ? LONG
+ Font used in status bar ULONG
+ Handle to user window ULONG
+ First keyboard indicator (-1 if none) SHORT
+ First host connected field (-1 if none) SHORT
+ First date time field (-1 if none) LONG
+ Field for keyboard hook LONG
+ Number of bar controls LONG
+ Bar controls PBAR_CTL
+ Id of user window BYTE [16]
+ Bar object call on create and destroy BYTE [9]
Font information
+ Font size USHORT
+ Font name [Size of font name]
Bar control information
+ Bar control data size USHORT
Bar control data
+ Rectangle for bar control RECTL [8 x ULONG]
+ Width LONG
+ Width in pixels LONG
+ Type of control LONG
+ Sub type of control LONG
+ Control flags ULONG
+ Object ID PSZ
+ Label of control PSZ
+ Control dependent text PSZ
+ Help ID (Only buttons) PSZ
+ Current text contents BYTE [81]
+ State (Control dependent usage) LONG
+ Data (Control dependent usage) PVOID
file - IOException - if an I/O error occurs.public static PhantomCBar createPhantomBar(PhantomControl bd, PhantomCUserWindow uw, PhantomFile data) throws IOException
IOException - if an I/O error occurs.public void saveRef(PhantomOutputFile file) throws IOException
file - IOException - if an I/O error occurs.public int getRefSaveSize()
public int getSaveSize()
public int getCreateFlags()
public int getFontSize()
public Vector<PhantomCBarControl> getBarControls()
public PhantomHostField getHostField(String hostFieldName)
public PhantomObject getObject(String objectName, String referer) throws IOException
IOExceptionpublic PhantomCBarControl getBarControl(String label)
label - either a label string, or an index to a bar controlpublic PhantomCBarControl getControlWithLabel(String label)
label - the label of the bar control that should be searched forpublic boolean needsReload()
needsReload in interface IReloadablepublic int reload(boolean force)
throws IOException
reload in interface IReloadableforce - - force the reload.IOExceptionPhantom® and NetPhantom® are registered trademarks of Nexum Technologies SARL.
© Copyright Nexum Technologies SARL, 2011. All rights reserved.