public class WSL
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
int |
handle |
Constructor and Description |
---|
WSL() |
Modifier and Type | Method and Description |
---|---|
void |
begin()
Begins a connection to Tamino by setting up the communication buffer.
|
protected void |
buildXIno()
Contructs the x-ino field from the key/value pairs in the hashmap
|
void |
close()
Closes a connection to Tamino by destroying the communication buffer.
|
int |
diagnose(java.lang.String db,
java.lang.String command) |
void |
end()
Ends a connection to Tamino for a given instance of WSL.
|
java.lang.String |
getAcceptCharset()
Retrieves the value for the desired character encoding in the Tamino
communication buffer.
|
byte[] |
getBodyContent() |
long |
getBodyLength() |
java.lang.String |
getContentType()
Retrieves the value of the mime-type of the body in the Tamino
communication buffer.
|
java.lang.String |
getInoHeader(java.lang.String key)
Retrieves the value from the hashmap for a given key, usually found in the HTTP header
|
int |
getNumProperty(java.lang.String key)
Retrieves the value of a numerical property.
|
java.lang.String |
getPassword()
Retrieves the current password header field in the Tamino
communication buffer.
|
java.lang.String |
getQueryString()
Retrieves the query string in the Tamino communication buffer.
|
java.lang.String |
getRequestMethod()
Retrieves the HTTP-like request method for the Tamino
communication.
|
byte[] |
getResponse()
Retrieves the contents of the Tamino response buffer.
|
java.lang.String |
getTextProperty(java.lang.String key)
Retrieves the value of a text property, i.e.
|
java.lang.String |
getUri()
Retrieves the URI of the proposed Tamino request, i.e.
|
java.lang.String |
getUserId()
Retrieves the current domain+username header field in the Tamino
communication buffer.
|
java.lang.String |
getXIno()
Retrieves the current x-ino header field in the Tamino communication
buffer.
|
void |
resetInoHeaders()
Resets all in header key/value pairs.
|
void |
setAcceptCharset(java.lang.String charset)
Sets the character encoding for the request and the response from
Tamino, e.g.
|
void |
setBody(byte[] buffer,
long length)
Sets the body in the Tamino communication buffer.
|
void |
setContentType(java.lang.String type)
Sets the mime-type of the body in the Tamino communication buffer.
|
int |
setInoHeader(java.lang.String key,
java.lang.String value)
Fills a hashmap with a key/value pair or deletes a key, usually found in the HTTP header
|
void |
setNumProperty(java.lang.String key,
int value)
Sets the value of a numerical property.
|
void |
setPassword(java.lang.String password)
Sets the password field in the Tamino communication buffer.
|
void |
setQueryString(java.lang.String query)
Sets the query string in the Tamino communication buffer, e.g.
|
void |
setRequestMethod(java.lang.String method)
Sets the value of the HTTP-like request method for the Tamino
communication.
|
void |
setUri(java.lang.String uri)
Sets the URI for the Tamino request in the form
/tamino/
|
void |
setUserId(java.lang.String userId)
Sets the domain+username field in the Tamino communication buffer.
|
void |
setXIno(java.lang.String xIno)
Sets the x-ino header field in the Tamino communication buffer.
|
int |
submit()
Submits a request to Tamino for a given instance of WSL.
|
int |
xql(java.lang.String db,
java.lang.String coll,
java.lang.String query) |
public WSL() throws TInvocationException
TInvocationException
public void end()
public int submit()
public void setNumProperty(java.lang.String key, int value)
key
- is the property name.value
- is the property value.public int getNumProperty(java.lang.String key)
key
- is the property name.public java.lang.String getTextProperty(java.lang.String key)
key
- is the property name.public byte[] getResponse()
public int diagnose(java.lang.String db, java.lang.String command)
public int xql(java.lang.String db, java.lang.String coll, java.lang.String query)
public void begin()
public void close()
public void setUri(java.lang.String uri)
uri
- is the path to the Tamino resource starting with /tamino/...public java.lang.String getUri()
public void setRequestMethod(java.lang.String method)
method
- specifies the HTTP-like request method.public java.lang.String getRequestMethod()
public void setQueryString(java.lang.String query)
query
- is the Tamino query string.public java.lang.String getQueryString()
public void setAcceptCharset(java.lang.String charset)
charset
- is the desired character set.public java.lang.String getAcceptCharset()
public void setContentType(java.lang.String type)
type
- is the mime-type of the body.public java.lang.String getContentType()
public void setUserId(java.lang.String userId)
userId
- is the value of the domain+username field.public java.lang.String getUserId()
public void setPassword(java.lang.String password)
password
- is the value of the password field.public java.lang.String getPassword()
public void setXIno(java.lang.String xIno)
xIno
- is the value of the x-ino header field.public java.lang.String getXIno()
public int setInoHeader(java.lang.String key, java.lang.String value)
key
- is the name of the header field, e.g. isolationLevelvalue
- is the value for the header field, e.g. stableCursorpublic java.lang.String getInoHeader(java.lang.String key)
key
- is the name of the header field, e.g. isolationLevelpublic void resetInoHeaders()
protected void buildXIno()
public void setBody(byte[] buffer, long length)
buffer
- is the contents.length
- is the length of the contents in bytes.public byte[] getBodyContent()
public long getBodyLength()
Copyright (c) 2017 Software AG. All Rights Reserved.