|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object de.smartics.properties.config.transfer.templatestream.Factory
public class Factory
Creates instances of StreamPropertySink
.
Constructor Summary | |
---|---|
Factory() Default constructor. |
Method Summary | |
---|---|
StreamPropertySink |
create() Creates an instance of PropertySink . |
String |
getEncoding() Returns the encoding to use to write to the file. |
void |
setConfigColumn(String configColumn) Sets the name of the optional configuration key column. |
void |
setDocumentExtro(String extro) Sets the text to write to the stream at the end before closing the stream. |
void |
setDocumentIntro(String intro) Sets the introduction to write to the stream at the start. |
void |
setEncoding(String encoding) Sets the encoding to use to write to the file. |
protected void |
setEscaper(ValueEscaper escaper) Sets the escaper for config key, property name and value. |
void |
setEscaperType(String type) Sets the type of the escaper for config key, property name and value. |
void |
setFile(String fileName) Sets the file to write to. |
void |
setLineExtro(String extro) Sets the text to write after each property provider. |
void |
setLineIntro(String intro) Sets the introduction to write before each property provider. |
void |
setNameColumn(String nameColumn) Sets the name of the property name column. |
void |
setStream(PrintWriter stream) Sets the stream to write to. |
void |
setTable(String table) Sets the name of the configuration table. |
void |
setTemplate(String template) Sets the template to apply on each property. |
void |
setValueColumn(String valueColumn) Sets the name of the property value column. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public Factory()
Method Detail |
---|
public final void setDocumentIntro(String intro)
intro
- the introduction to write to the stream at the start.
public final void setDocumentExtro(String extro)
extro
- the text to write to the stream at the end before closing the stream.
public final void setLineIntro(String intro)
intro
- the introduction to write before each property provider.
public final void setLineExtro(String extro)
extro
- the text to write after each property provider.
public final void setTemplate(String template)
template
- the template to apply on each property.
public final void setTable(String table) throws NullPointerException, IllegalArgumentException
table
- the name of the configuration table.
NullPointerException
- if
table
is
null
.
IllegalArgumentException
- if
table
is blank.
public final void setConfigColumn(String configColumn) throws NullPointerException, IllegalArgumentException
configColumn
- the name of the optional configuration key column.
NullPointerException
- if
configColumn
is
null
.
IllegalArgumentException
- if
configColumn
is blank.
public final void setNameColumn(String nameColumn) throws NullPointerException, IllegalArgumentException
nameColumn
- the name of the property name column.
NullPointerException
- if
nameColumn
is
null
.
IllegalArgumentException
- if
nameColumn
is blank.
public final void setValueColumn(String valueColumn) throws NullPointerException, IllegalArgumentException
valueColumn
- the name of the property value column.
NullPointerException
- if
valueColumn
is
null
.
IllegalArgumentException
- if
valueColumn
is blank.
public final void setStream(PrintWriter stream)
stream
- the stream to write to.
public final void setFile(String fileName)
fileName
- the name of the file to write to.
public final void setEncoding(String encoding)
encoding
- the encoding to use to write to the file.
public final String getEncoding()
protected final void setEscaper(ValueEscaper escaper)
escaper
- the escaper for config key, property name and value.
public final void setEscaperType(String type) throws TransferException
type
- the type of the escaper for config key, property name and value.
TransferException
- if the type cannot be instantiated.
public StreamPropertySink create() throws TransferException
PropertySink
.
create
in interface
PropertySinkFactory<StreamPropertySink>
PropertySink
.
TransferException
- on any problem opening the stream.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |