Class Vinci
- java.lang.Object
-
- org.apache.uima.collection.impl.cpm.vinci.Vinci
-
public class Vinci extends java.lang.Object
The Class Vinci.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
Vinci.AFFactory
A factory for creating AF objects.
-
Constructor Summary
Constructors Constructor Description Vinci()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static java.lang.String
extractKEYSAsString(AFrame frame)
Extract KEYS as string.private AFrame
getAFrame()
Returns a new VinciFrame.static java.lang.String
getContentFromDATACas(CasData aCas)
Gets the content from DATA cas.static java.lang.String
getFeatureValueByType(CasData aCAS, java.lang.String featureName)
Gets the feature value by type.static AFrame
produceAFrame(java.lang.String cmd, java.lang.String content)
Produce A frame.static AFrame
replyWithAnalysis(BaseClient conn, VinciFrame requestFrame)
Package theVinciFrame
containing result of the requested operation into a Vinci Data frame.static AFrame
replyWithAnalysis(VinciClient conn, VinciFrame requestFrame)
Package theVinciFrame
containing result of the requested operation into a Vinci Data frame.VinciFrame
replyWithError(java.lang.String errorMsg)
Creates and populates an error frame.static java.lang.String
stripVinciFrame(VinciFrame aFrame)
Returns a content from a given VinciFrame.
-
-
-
Field Detail
-
VNS_HOST
public static final java.lang.String VNS_HOST
The Constant VNS_HOST.- See Also:
- Constant Field Values
-
VNS_PORT
public static final java.lang.String VNS_PORT
The Constant VNS_PORT.- See Also:
- Constant Field Values
-
-
Method Detail
-
getAFrame
private AFrame getAFrame()
Returns a new VinciFrame.- Returns:
VinciFrame
instance
-
replyWithError
public VinciFrame replyWithError(java.lang.String errorMsg)
Creates and populates an error frame.- Parameters:
errorMsg
- - error message to place in the error frame- Returns:
VinciFrame
instance containing error
-
replyWithAnalysis
public static AFrame replyWithAnalysis(BaseClient conn, VinciFrame requestFrame) throws java.lang.Exception
Package theVinciFrame
containing result of the requested operation into a Vinci Data frame.- Parameters:
conn
- the connectionrequestFrame
-VinciFrame
containing result of thsi service operation- Returns:
VinciFrame
VinciData frame.- Throws:
java.lang.Exception
- -
-
replyWithAnalysis
public static AFrame replyWithAnalysis(VinciClient conn, VinciFrame requestFrame) throws java.lang.Exception
Package theVinciFrame
containing result of the requested operation into a Vinci Data frame.- Parameters:
conn
- the connectionrequestFrame
-VinciFrame
containing result of thsi service operation- Returns:
VinciFrame
VinciData frame.- Throws:
java.lang.Exception
- the exception
-
produceAFrame
public static AFrame produceAFrame(java.lang.String cmd, java.lang.String content)
Produce A frame.- Parameters:
cmd
- the cmdcontent
- the content- Returns:
- the a frame
-
extractKEYSAsString
public static java.lang.String extractKEYSAsString(AFrame frame)
Extract KEYS as string.- Parameters:
frame
- the frame- Returns:
- the string
-
getFeatureValueByType
public static java.lang.String getFeatureValueByType(CasData aCAS, java.lang.String featureName)
Gets the feature value by type.- Parameters:
aCAS
- the a CASfeatureName
- the feature name- Returns:
- the feature value by type
-
getContentFromDATACas
public static java.lang.String getContentFromDATACas(CasData aCas)
Gets the content from DATA cas.- Parameters:
aCas
- the a cas- Returns:
- the content from DATA cas
-
stripVinciFrame
public static java.lang.String stripVinciFrame(VinciFrame aFrame)
Returns a content from a given VinciFrame.- Parameters:
aFrame
- the a frame- Returns:
- the string
-
-