Class PointCardRWService
java.lang.Object
de.gmxhome.conrad.jpos.jpos_base.JposBase
de.gmxhome.conrad.jpos.jpos_base.pointcardrw.PointCardRWService
- All Implemented Interfaces:
jpos.loader.JposServiceInstance
,jpos.services.BaseService
,jpos.services.PointCardRWService110
,jpos.services.PointCardRWService111
,jpos.services.PointCardRWService112
,jpos.services.PointCardRWService113
,jpos.services.PointCardRWService114
,jpos.services.PointCardRWService115
,jpos.services.PointCardRWService116
,jpos.services.PointCardRWService15
,jpos.services.PointCardRWService16
,jpos.services.PointCardRWService17
,jpos.services.PointCardRWService18
,jpos.services.PointCardRWService19
PointCardRW service implementation. For more details about getter, setter and method implementations,
see JposBase.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic class
Class describing alignment escape sequences ESC|xA, where x is one of c or r.static class
Class describing embedded escape sequences ESC|[*]#E.static class
Class describing font typeface selection escape sequences ESC|#fT.static class
Class describing normalize escape sequences ESC|N.static class
Class describing scaling escape sequences ESC|[#][x]C, where x is one of h or v.static class
Class describing simple attribute setting escape sequences ESC|xC, where x is one of b, i or rv.static class
Class describing line escape sequences ESC|[!][#]xC, where x is one of u or st.static class
Class describing unknown escape sequence.static class
Class describing printable part of print data.static class
Helper class used to control parsed output data. -
Field Summary
FieldsModifier and TypeFieldDescriptionInstance of a class implementing the PointCardRWInterface for point card reader / writer specific setter and method calls bound to the property set.Fields inherited from class de.gmxhome.conrad.jpos.jpos_base.JposBase
Device, DeviceInterface, Props
-
Constructor Summary
ConstructorsConstructorDescriptionPointCardRWService(PointCardRWProperties props, JposDevice device)
Constructor. -
Method Summary
Modifier and TypeMethodDescriptionvoid
beginInsertion(int timeout)
void
beginRemoval(int timeout)
void
void
clearPrintWrite(int kind, int hposition, int vposition, int width, int height)
void
void
boolean
int
int
boolean
boolean
boolean
boolean
boolean
boolean
boolean
boolean
boolean
boolean
boolean
boolean
int
int
int
int
int
int
int
int
boolean
int
int
int
int
int
int
int
int
int
int
int
int
int
void
Generates logging message for internal property array representing a range of UPOS properties.void
Generates logging message for internal property array representing a range of UPOS properties.outputDataParts(String data)
Parses output data for escape sequences.void
Checks whether the given string holds data that cannot be printed precisely on slip as expected.void
printWrite(int kind, int hposition, int vposition, String data)
void
rotatePrint(int rotation)
void
setCharacterSet(int code)
void
setLineChars(int chars)
void
setLineHeight(int height)
void
setLineSpacing(int spacing)
void
setMapCharacterSet(boolean flag)
void
setMapMode(int mode)
void
setTracksToRead(int tracks)
void
setTracksToWrite(int tracks)
void
setWrite1Data(String trackdata)
void
setWrite2Data(String trackdata)
void
setWrite3Data(String trackdata)
void
setWrite4Data(String trackdata)
void
setWrite5Data(String trackdata)
void
setWrite6Data(String trackdata)
void
validateData(String data)
Methods inherited from class de.gmxhome.conrad.jpos.jpos_base.JposBase
callNowOrLater, check, check, check, check, checkBusy, checkClaimed, checkEnabled, checkEnabledUnclaimed, checkFirstEnabled, checkHealth, checkNoChangedOrClaimed, checkOpened, claim, clearInput, clearInputProperties, clearOutput, close, compareFirmwareVersion, deepToString, deleteInstance, directIO, getAsyncMode, getAutoDisable, getCapCompareFirmwareVersion, getCapPowerReporting, getCapStatisticsReporting, getCapUpdateFirmware, getCapUpdateStatistics, getCheckHealthText, getClaimed, getDataCount, getDataEventEnabled, getDeviceEnabled, getDeviceServiceDescription, getDeviceServiceVersion, getFreezeEvents, getOutputID, getPhysicalDeviceDescription, getPhysicalDeviceName, getPowerNotify, getPowerState, getPropertyString, getState, logAsyncCall, logCall, logCall, logGet, logGet, logPreCall, logPreCall, logPreSet, logSet, open, release, removeOuterArraySpecifier, resetStatistics, retrieveStatistics, setAsyncMode, setAutoDisable, setDataEventEnabled, setDeviceEnabled, setFreezeEvents, setPowerNotify, signalRelease, startClaiming, updateFirmware, updateStatistics
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface jpos.services.BaseService
checkHealth, claim, close, directIO, getCheckHealthText, getClaimed, getDeviceEnabled, getDeviceServiceDescription, getDeviceServiceVersion, getFreezeEvents, getPhysicalDeviceDescription, getPhysicalDeviceName, getState, open, release, setDeviceEnabled, setFreezeEvents
Methods inherited from interface jpos.loader.JposServiceInstance
deleteInstance
Methods inherited from interface jpos.services.PointCardRWService110
clearInputProperties
Methods inherited from interface jpos.services.PointCardRWService15
clearInput, clearOutput, getCapPowerReporting, getDataCount, getDataEventEnabled, getOutputID, getPowerNotify, getPowerState, setDataEventEnabled, setPowerNotify
Methods inherited from interface jpos.services.PointCardRWService18
getCapStatisticsReporting, getCapUpdateStatistics, resetStatistics, retrieveStatistics, updateStatistics
Methods inherited from interface jpos.services.PointCardRWService19
compareFirmwareVersion, getCapCompareFirmwareVersion, getCapUpdateFirmware, updateFirmware
-
Field Details
-
PointCardRW
Instance of a class implementing the PointCardRWInterface for point card reader / writer specific setter and method calls bound to the property set. Almost always the same object as Data.
-
-
Constructor Details
-
PointCardRWService
Constructor. Stores given property set and device implementation object.- Parameters:
props
- Property set.device
- Device implementation object.
-
-
Method Details
-
getCapMapCharacterSet
public boolean getCapMapCharacterSet() throws jpos.JposException- Specified by:
getCapMapCharacterSet
in interfacejpos.services.PointCardRWService17
- Throws:
jpos.JposException
-
getMapCharacterSet
public boolean getMapCharacterSet() throws jpos.JposException- Specified by:
getMapCharacterSet
in interfacejpos.services.PointCardRWService17
- Throws:
jpos.JposException
-
getCapBold
public boolean getCapBold() throws jpos.JposException- Specified by:
getCapBold
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
getCapCardEntranceSensor
public int getCapCardEntranceSensor() throws jpos.JposException- Specified by:
getCapCardEntranceSensor
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
getCapCharacterSet
public int getCapCharacterSet() throws jpos.JposException- Specified by:
getCapCharacterSet
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
getCapCleanCard
public boolean getCapCleanCard() throws jpos.JposException- Specified by:
getCapCleanCard
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
getCapClearPrint
public boolean getCapClearPrint() throws jpos.JposException- Specified by:
getCapClearPrint
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
getCapDhigh
public boolean getCapDhigh() throws jpos.JposException- Specified by:
getCapDhigh
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
getCapDwide
public boolean getCapDwide() throws jpos.JposException- Specified by:
getCapDwide
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
getCapDwideDhigh
public boolean getCapDwideDhigh() throws jpos.JposException- Specified by:
getCapDwideDhigh
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
getCapItalic
public boolean getCapItalic() throws jpos.JposException- Specified by:
getCapItalic
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
getCapLeft90
public boolean getCapLeft90() throws jpos.JposException- Specified by:
getCapLeft90
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
getCapPrint
public boolean getCapPrint() throws jpos.JposException- Specified by:
getCapPrint
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
getCapPrintMode
public boolean getCapPrintMode() throws jpos.JposException- Specified by:
getCapPrintMode
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
getCapRight90
public boolean getCapRight90() throws jpos.JposException- Specified by:
getCapRight90
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
getCapRotate180
public boolean getCapRotate180() throws jpos.JposException- Specified by:
getCapRotate180
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
getCapTracksToRead
public int getCapTracksToRead() throws jpos.JposException- Specified by:
getCapTracksToRead
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
getCapTracksToWrite
public int getCapTracksToWrite() throws jpos.JposException- Specified by:
getCapTracksToWrite
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
getCardState
public int getCardState() throws jpos.JposException- Specified by:
getCardState
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
getCharacterSet
public int getCharacterSet() throws jpos.JposException- Specified by:
getCharacterSet
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
getCharacterSetList
- Specified by:
getCharacterSetList
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
getFontTypeFaceList
- Specified by:
getFontTypeFaceList
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
getLineChars
public int getLineChars() throws jpos.JposException- Specified by:
getLineChars
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
getLineCharsList
- Specified by:
getLineCharsList
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
getLineHeight
public int getLineHeight() throws jpos.JposException- Specified by:
getLineHeight
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
getLineSpacing
public int getLineSpacing() throws jpos.JposException- Specified by:
getLineSpacing
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
getLineWidth
public int getLineWidth() throws jpos.JposException- Specified by:
getLineWidth
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
getMapMode
public int getMapMode() throws jpos.JposException- Specified by:
getMapMode
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
getMaxLines
public int getMaxLines() throws jpos.JposException- Specified by:
getMaxLines
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
getPrintHeight
public int getPrintHeight() throws jpos.JposException- Specified by:
getPrintHeight
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
getReadState1
public int getReadState1() throws jpos.JposException- Specified by:
getReadState1
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
getReadState2
public int getReadState2() throws jpos.JposException- Specified by:
getReadState2
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
getRecvLength1
public int getRecvLength1() throws jpos.JposException- Specified by:
getRecvLength1
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
getRecvLength2
public int getRecvLength2() throws jpos.JposException- Specified by:
getRecvLength2
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
getSidewaysMaxChars
public int getSidewaysMaxChars() throws jpos.JposException- Specified by:
getSidewaysMaxChars
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
getSidewaysMaxLines
public int getSidewaysMaxLines() throws jpos.JposException- Specified by:
getSidewaysMaxLines
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
getTracksToRead
public int getTracksToRead() throws jpos.JposException- Specified by:
getTracksToRead
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
getTracksToWrite
public int getTracksToWrite() throws jpos.JposException- Specified by:
getTracksToWrite
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
getTrack1Data
- Specified by:
getTrack1Data
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
getTrack2Data
- Specified by:
getTrack2Data
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
getTrack3Data
- Specified by:
getTrack3Data
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
getTrack4Data
- Specified by:
getTrack4Data
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
getTrack5Data
- Specified by:
getTrack5Data
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
getTrack6Data
- Specified by:
getTrack6Data
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
getWriteState1
public int getWriteState1() throws jpos.JposException- Specified by:
getWriteState1
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
getWriteState2
public int getWriteState2() throws jpos.JposException- Specified by:
getWriteState2
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
getWrite1Data
- Specified by:
getWrite1Data
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
getWrite2Data
- Specified by:
getWrite2Data
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
getWrite3Data
- Specified by:
getWrite3Data
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
getWrite4Data
- Specified by:
getWrite4Data
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
getWrite5Data
- Specified by:
getWrite5Data
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
getWrite6Data
- Specified by:
getWrite6Data
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
setCharacterSet
public void setCharacterSet(int code) throws jpos.JposException- Specified by:
setCharacterSet
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
setLineChars
public void setLineChars(int chars) throws jpos.JposException- Specified by:
setLineChars
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
setLineHeight
public void setLineHeight(int height) throws jpos.JposException- Specified by:
setLineHeight
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
setLineSpacing
public void setLineSpacing(int spacing) throws jpos.JposException- Specified by:
setLineSpacing
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
setMapCharacterSet
public void setMapCharacterSet(boolean flag) throws jpos.JposException- Specified by:
setMapCharacterSet
in interfacejpos.services.PointCardRWService17
- Throws:
jpos.JposException
-
setMapMode
public void setMapMode(int mode) throws jpos.JposException- Specified by:
setMapMode
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
setTracksToRead
public void setTracksToRead(int tracks) throws jpos.JposException- Specified by:
setTracksToRead
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
setTracksToWrite
public void setTracksToWrite(int tracks) throws jpos.JposException- Specified by:
setTracksToWrite
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
setWrite1Data
- Specified by:
setWrite1Data
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
setWrite2Data
- Specified by:
setWrite2Data
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
setWrite3Data
- Specified by:
setWrite3Data
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
setWrite4Data
- Specified by:
setWrite4Data
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
setWrite5Data
- Specified by:
setWrite5Data
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
setWrite6Data
- Specified by:
setWrite6Data
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
beginInsertion
public void beginInsertion(int timeout) throws jpos.JposException- Specified by:
beginInsertion
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
beginRemoval
public void beginRemoval(int timeout) throws jpos.JposException- Specified by:
beginRemoval
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
cleanCard
public void cleanCard() throws jpos.JposException- Specified by:
cleanCard
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
clearPrintWrite
public void clearPrintWrite(int kind, int hposition, int vposition, int width, int height) throws jpos.JposException- Specified by:
clearPrintWrite
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
endInsertion
public void endInsertion() throws jpos.JposException- Specified by:
endInsertion
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
endRemoval
public void endRemoval() throws jpos.JposException- Specified by:
endRemoval
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
rotatePrint
public void rotatePrint(int rotation) throws jpos.JposException- Specified by:
rotatePrint
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
validateData
- Specified by:
validateData
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
printWrite
public void printWrite(int kind, int hposition, int vposition, String data) throws jpos.JposException- Specified by:
printWrite
in interfacejpos.services.PointCardRWService15
- Throws:
jpos.JposException
-
outputDataParts
Parses output data for escape sequences. See UPOS specification for PointCardRW, chapter Data Characters and Escape Sequences. Returns list of objects that describe all parts of the output string. These objects can be used by validate and print functions to check print data and to generate generic output data. Possible objects in list have one of the following types:- PrintData - Class containing character strings with printable characters only. See PrintData for details.
- EscNormalize - Class containing information about details of a normalize command. See EscNormalize for details.
- EscEmbedded - Class containing information about details of a embedded data command. See EscEmbedded for details.
- EscFontTypeface - Class containing information about details of a font typeface command. See EscFontTypeface for details.
- EscAlignment - Class containing information about details of an alignment command. See EscAlignment for details.
- EscScale - Class containing information about details of a scale command. See EscScale for details.
- EscSimple - Class containing information about details of a simple attribute command. See EscSimple for details.
- EscLine - Class containing information about details of an added line command. See EscLine for details.
- EscUnknown - Class containing information about details of an unknown escape sequence.
- Parameters:
data
- Character string to be printed. May contain CR, LF and ESC sequences as described in the UPOS specification.- Returns:
- List of objects that describe all parts of data.
-
plausibilityCheckData
public void plausibilityCheckData(List<PointCardRWService.PrintDataPart> data) throws jpos.JposExceptionChecks whether the given string holds data that cannot be printed precisely on slip as expected. See UPOS method ValidateData for details.
this method checks only the general ability for those features that can be checked via capabilitys or other property values. More detailed checks must be performed by device specific service implementations.- Parameters:
data
- Data to be checked. See UPOS method ValidateData for more details.- Throws:
jpos.JposException
- See UPOS specification of method ValidateData. Error code can be E_ILLEGAL or E_FAILURE.
-
logGet
Generates logging message for internal property array representing a range of UPOS properties.- Parameters:
obj
- The array that contains the property range.index
- The index of the array to be logged.mask
- The UPOS property name mask, e.g for property Track1 ... Track3 this can be Track%d.modifier
- The value to be formatted. An example: For mask = Track%d and modifier 2, the resulting property name would be Track2.
-
logSet
Generates logging message for internal property array representing a range of UPOS properties.- Parameters:
obj
- The array that contains the property range.index
- The index of the array to be logged.mask
- The UPOS property name mask, e.g for property Track1 ... Track3 this can be Track%d.modifier
- The value to be formatted. An example: For mask = Track%d and modifier 2, the resulting property name would be Track2.
-