Package SampleCombiDevice
Class LineDisplay
java.lang.Object
de.gmxhome.conrad.jpos.jpos_base.JposCommonProperties
de.gmxhome.conrad.jpos.jpos_base.linedisplay.LineDisplayProperties
SampleCombiDevice.LineDisplay
- All Implemented Interfaces:
JposBaseInterface
,LineDisplayInterface
Class implementing the LineDisplayInterface for the sample combi device.
-
Field Summary
Fields inherited from class de.gmxhome.conrad.jpos.jpos_base.linedisplay.LineDisplayProperties
BlinkRate, CapBitmap, CapBlink, CapBlinkRate, CapBrightness, CapCharacterSet, CapCursorType, CapCustomGlyph, CapDescriptors, CapHMarquee, CapICharWait, CapMapCharacterSet, CapReadBack, CapReverse, CapScreenMode, CapVMarquee, CharacterSet, CharacterSetDef, CharacterSetList, Columns, CurrentWindow, CursorColumn, CursorRow, CursorType, CursorUpdate, CustomGlyphList, DeviceBrightness, DeviceColumns, DeviceDescriptors, DeviceRows, DeviceWindows, GlyphHeight, GlyphWidth, InterCharacterWait, MapCharacterSet, MarqueeFormat, MarqueeRepeatWait, MarqueeType, MarqueeUnitWait, MaximumX, MaximumY, Rows, ScreenMode, ScreenModeList
Fields inherited from class de.gmxhome.conrad.jpos.jpos_base.JposCommonProperties
AllowAlwaysSetProperties, AllowDeprecatedMethods, AsyncInputActive, AsyncMode, AutoDisable, CapStatisticsReporting, CapUpdateStatistics, CheckHealthText, Claimed, Claiming, ClaimWaiters, CurrentCommands, CurrentUnitID, DataCount, DataEventEnabled, DataEventList, Device, DeviceEnabled, DeviceServiceDescription, DeviceServiceVersion, DevProps, ErrorString, ErrorUnits, EventCB, EventList, EventSource, EventString, EventUnitID, EventUnits, ExclusiveAllowed, ExclusiveNo, ExclusiveUse, ExclusiveYes, FirstEnableHappened, FlagWhenIdle, FlagWhenIdleStatusValue, FreezeEvents, Index, LogicalName, MaximumConfirmationEventWaitingTime, OutputID, PowerNotify, PowerState, SerializedRequestRunner, SerializedRequests, State, StrictFIFOEventHandling, SuspendedCommands, SuspendedConcurrentCommands, UnitsOnline, UsesSubsystemUnits
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
characterSet(int charset)
Final part of setting CharacterSet.void
checkHealth(int level)
Final part of CheckHealth method.void
claim(int timeout)
Final part of setting claim.void
Final part of ClearText method.void
deviceBrightness(int b)
Final part of setting DeviceBrightness.void
deviceEnabled(boolean enable)
Final part of setting DeviceEnabled.void
displayText(DisplayText request)
Final part of displayText method.displayText(String text, int attribute)
Validation part of DisplayText method.void
interCharacterWait(int b)
Final part of setting InterCharacterWait.void
refreshWindow(int index)
Final part of RefreshWindow method.void
release()
Final part of release method.void
scrollText(int direction, int units)
Final part of ScrollText method.Methods inherited from class de.gmxhome.conrad.jpos.jpos_base.linedisplay.LineDisplayProperties
blinkRate, clearDescriptors, createWindow, currentWindow, cursorColumn, cursorRow, cursorType, cursorUpdate, defineGlyph, destroyWindow, displayBitmap, initOnFirstEnable, initOnOpen, mapCharacterSet, marqueeFormat, marqueeRepeatWait, marqueeType, marqueeUnitWait, readCharacterAtCursor, screenMode, setBitmap, setDescriptor
Methods inherited from class de.gmxhome.conrad.jpos.jpos_base.JposCommonProperties
addProperties, asyncMode, attachWaiter, autoDisable, checkForDeprecation, checkProperties, clearDataProperties, clearErrorProperties, clearInput, clearOutput, clearOutputErrorProperties, close, compareFirmwareVersion, dataEventEnabled, directIO, directIO, flagWhenIdle, freezeEvents, getClaimingInstance, handlePowerStateOnEnable, initOnClaim, initOnEnable, newJposOutputRequest, open, powerNotify, releaseWaiter, removeFromPropertySetList, resetStatistics, retrieveStatistics, retryInput, retryOutput, signalWaiter, unitDataCount, updateFirmware, updateFirmware, updateStatistics, waitWaiter
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface de.gmxhome.conrad.jpos.jpos_base.JposBaseInterface
asyncMode, autoDisable, clearInput, clearOutput, close, compareFirmwareVersion, dataEventEnabled, directIO, directIO, flagWhenIdle, freezeEvents, handlePowerStateOnEnable, newJposOutputRequest, open, powerNotify, removeFromPropertySetList, resetStatistics, retrieveStatistics, retryInput, retryOutput, unitDataCount, updateFirmware, updateFirmware, updateStatistics
-
Constructor Details
-
LineDisplay
Constructor. Gets instance of Device to be used as communication object. Device index for sample is always 0.- Parameters:
dev
- Instance of Device this object belongs to.
-
-
Method Details
-
deviceEnabled
public void deviceEnabled(boolean enable) throws jpos.JposExceptionDescription copied from interface:JposBaseInterface
Final part of setting DeviceEnabled. Can be overwritten within derived classes. Performs initOnEnable method of corresponding property set in addition to setting DeviceEnabled. This method will be called only if the following plausibility checks lead to a positive result:- Device has not been closed,
- ExclusiveUse equals ExclusiveYes: Device is claimed,
- DeviceEnabled != enabled.
- Specified by:
deviceEnabled
in interfaceJposBaseInterface
- Overrides:
deviceEnabled
in classJposCommonProperties
- Parameters:
enable
- True to enable, false to disable- Throws:
jpos.JposException
- If an error occurs during enable or disable
-
claim
public void claim(int timeout) throws jpos.JposExceptionDescription copied from interface:JposBaseInterface
Final part of setting claim. Can be overwritten within derived classes. This method will be called only if the following plausibility checks lead to a positive result:- Device has not been closed,
- The device is not claimed,
- ExclusiveUse dos not equal ExclusiveNo,
- timeout is negative not equal to FOREVER.
- Specified by:
claim
in interfaceJposBaseInterface
- Overrides:
claim
in classJposCommonProperties
- Parameters:
timeout
- see UPOS specification, method Claim- Throws:
jpos.JposException
- If an error occurs while claiming the device
-
release
public void release() throws jpos.JposExceptionDescription copied from interface:JposBaseInterface
Final part of release method. Can be overwritten in derived class, if necessary. This method will be called only if the following plausibility checks lead to a positive result:- Device is claimed,
- ExclusiveUse equals ExclusiveYes: Device is not enabled.
- Specified by:
release
in interfaceJposBaseInterface
- Overrides:
release
in classJposCommonProperties
- Throws:
jpos.JposException
- See UPOS specification, method Release
-
checkHealth
public void checkHealth(int level) throws jpos.JposExceptionDescription copied from interface:JposBaseInterface
Final part of CheckHealth method. Can be overwritten in derived class, if necessary. Keep in mind that dvice class specific checks (e.g. check of Claimed or DeviceEnabled) must be done within derived classes. This method will be called only if the following plausibility checks lead to a positive result:- Device is neither enabled nor claimed.
- Specified by:
checkHealth
in interfaceJposBaseInterface
- Overrides:
checkHealth
in classJposCommonProperties
- Parameters:
level
- See UPOS specification, method CheckHealth- Throws:
jpos.JposException
- See UPOS specification, method CheckHealth
-
clearText
public void clearText() throws jpos.JposExceptionDescription copied from interface:LineDisplayInterface
Final part of ClearText method. Can be overwritten in derived class, if necessary. This method will be called only if the following plausibility checks lead to a positive result:- Device is enabled,
- MarqueeType is DISP_MT_NONE or DISP_MT_INIT.
- Specified by:
clearText
in interfaceLineDisplayInterface
- Overrides:
clearText
in classLineDisplayProperties
- Throws:
jpos.JposException
- If an error occurs.
-
characterSet
public void characterSet(int charset) throws jpos.JposExceptionDescription copied from interface:LineDisplayInterface
Final part of setting CharacterSet. Can be overwritten within derived classes, if necessary. This method will be called only if the following plausibility checks lead to a positive result:- Device has not been closed,
- The new value is one of the values specified in CharacterSetList,
- internal property AllowAlwaysSetProperties is true or charset equals the previous value of CharacterSet.
- Specified by:
characterSet
in interfaceLineDisplayInterface
- Overrides:
characterSet
in classLineDisplayProperties
- Parameters:
charset
- New CharacterSet value- Throws:
jpos.JposException
- If an error occurs during enable or disable
-
deviceBrightness
public void deviceBrightness(int b) throws jpos.JposExceptionDescription copied from interface:LineDisplayInterface
Final part of setting DeviceBrightness. Can be overwritten within derived classes, if necessary. This method will be called only if the following plausibility checks lead to a positive result:- Device has not been closed,
- The new value is ≥ 0 and ≤ 100,
- internal property AllowAlwaysSetProperties is true or brightness equals the previous value of DeviceBrightness.
- Specified by:
deviceBrightness
in interfaceLineDisplayInterface
- Overrides:
deviceBrightness
in classLineDisplayProperties
- Parameters:
b
- New DeviceBrightness value- Throws:
jpos.JposException
- If an error occurs during enable or disable
-
scrollText
public void scrollText(int direction, int units) throws jpos.JposExceptionDescription copied from interface:LineDisplayInterface
Final part of ScrollText method. Can be overwritten in derived class, if necessary. This method will be called only if the following plausibility checks lead to a positive result:- Device is enabled,
- MarqueeType equals DISP_MT_NONE,
- InterCharacterWait equals 0,
- direction is DISP_ST_UP, DISP_ST_DOWN, DISP_ST_LEFT or DISP_ST_RIGHT.
- units ≥ 0,
- Specified by:
scrollText
in interfaceLineDisplayInterface
- Overrides:
scrollText
in classLineDisplayProperties
- Parameters:
direction
- Scrolling direction.units
- Number of columns or rows to scroll.- Throws:
jpos.JposException
- If an error occurs.
-
displayText
Description copied from interface:LineDisplayInterface
Validation part of DisplayText method. Can be overwritten in derived class, if necessary. This method will be called only if the following plausibility checks lead to a positive result:- Device is enabled,
- data is not null,
- MarqueeType equals DISP_MT_NONE or DISP_MT_INIT.
- Specified by:
displayText
in interfaceLineDisplayInterface
- Overrides:
displayText
in classLineDisplayProperties
- Parameters:
text
- Display data.attribute
- Display attributes.- Returns:
- DisplayText object for use in final part.
- Throws:
jpos.JposException
- If an error occurs.
-
interCharacterWait
public void interCharacterWait(int b) throws jpos.JposExceptionDescription copied from interface:LineDisplayInterface
Final part of setting InterCharacterWait. Can be overwritten within derived classes, if necessary. This method will be called only if the following plausibility checks lead to a positive result:- Device has not been closed,
- CapICharWait is false: The new value is 0,
- CapICharWait is true: The new value is ≥ 0,
- internal property AllowAlwaysSetProperties is true or millisec equals the previous value of InterCharacterWait.
- Specified by:
interCharacterWait
in interfaceLineDisplayInterface
- Overrides:
interCharacterWait
in classLineDisplayProperties
- Parameters:
b
- New InterCharacterWait value- Throws:
jpos.JposException
- If an error occurs during enable or disable
-
displayText
Description copied from interface:LineDisplayInterface
Final part of displayText method. Can be overwritten within derived classes, if necessary. The parameters of the method will be passed via a DisplayText object. This method will be called when the corresponding operation shall be performed, either synchronously or asynchronously (if InterCharacterWait is > 0). All plausibility checks have been made before, only runtime errors can occur.- Specified by:
displayText
in interfaceLineDisplayInterface
- Overrides:
displayText
in classLineDisplayProperties
- Parameters:
request
- Output request object returned by validation method that contains all parameters to be used by DisplayText.- Throws:
jpos.JposException
- If an error occurs.
-
refreshWindow
public void refreshWindow(int index) throws jpos.JposExceptionDescription copied from interface:LineDisplayInterface
Final part of RefreshWindow method. Can be overwritten in derived class, if necessary. This method will be called only if the following plausibility checks lead to a positive result:- Device is enabled,
- MarqueeType equals DISP_MT_NONE or DISP_MT_INIT,
- window is between 0 and DeviceWindows.
- Specified by:
refreshWindow
in interfaceLineDisplayInterface
- Overrides:
refreshWindow
in classLineDisplayProperties
- Parameters:
index
- The window to be refreshed.- Throws:
jpos.JposException
- If an error occurs.
-