org.tm4j.tologx
Interface TologFragmentBuilder

All Known Implementing Classes:
TologFragmentBuilderImpl

public interface TologFragmentBuilder

The interface for implementations which export a TologResultsSet into a TopicMapFragment.


Method Summary
 void exportResultsSet(TologResultsSet rs)
          Perform the export with the currently specified export parameters.
 void setConvertRowInformation(boolean convertRowInfo)
          Set the flag which indicates whether or not row information should be exported.
 void setFragment(TopicMapFragment fragment)
          Set the TopicMapFragment into which the results set should be exported.
 void setGenerateVarTopicNames(boolean genVarTopicNames)
          Set the flag which indicates whether or not topics representing the results set variables should be given base names.
 void setGenerateVarTopicSubjectIndicators(boolean genVarTopicSI)
          Set the flag which indicates whether or not topics representing the results set variables should be given subject indicators.
 void setRowAssociationTypeName(java.lang.String rowAssocTypeName)
          Sets the base name string to be assigned to the topic which types the row associations generated if the convertRowInformation option is set to true.
 void setVarTopicNamePrefix(java.lang.String namePrefix)
          Sets the string to be prepended to the base name string generated for topics which represent results set variables.
 void setVarTopicSubjectIndicatorPrefix(java.lang.String vtPrefix)
          Sets the prefix part of the subject indicator locator address to be generated for results set variables.
 

Method Detail

setFragment

public void setFragment(TopicMapFragment fragment)
Set the TopicMapFragment into which the results set should be exported.

Parameters:
fragment - the topic map fragment to export to.

setConvertRowInformation

public void setConvertRowInformation(boolean convertRowInfo)
Set the flag which indicates whether or not row information should be exported. If true then the exported topic map fragment will contain one association for each row in the TologResultsSet. Each association will have one member for each column in the results set with a single player for that member.


setGenerateVarTopicSubjectIndicators

public void setGenerateVarTopicSubjectIndicators(boolean genVarTopicSI)
Set the flag which indicates whether or not topics representing the results set variables should be given subject indicators.

Parameters:
genVarTopicSI - true if the topics representing results set variables should be given subject indicators, false otherwise.

setVarTopicSubjectIndicatorPrefix

public void setVarTopicSubjectIndicatorPrefix(java.lang.String vtPrefix)
Sets the prefix part of the subject indicator locator address to be generated for results set variables. The final form of the locator addresses generated will be {vtPrefix}{variablename}. It is the responsibility of the caller to ensure that the prefix is such that these generated addresses are valid URI strings.

Parameters:
vtPrefix - the prefix string to be used for generating the subject indicator locators for the topics representing results set variables.

setGenerateVarTopicNames

public void setGenerateVarTopicNames(boolean genVarTopicNames)
Set the flag which indicates whether or not topics representing the results set variables should be given base names.

Parameters:
genVarTopicNames - true if the topics representing results set variables should be given base names, false otherwise.

setVarTopicNamePrefix

public void setVarTopicNamePrefix(java.lang.String namePrefix)
Sets the string to be prepended to the base name string generated for topics which represent results set variables. The final form of the generated names will be {namePrefix}{variable name}.

Parameters:
namePrefix - the prefix string used in generating names for the topics which represent results set variables.

setRowAssociationTypeName

public void setRowAssociationTypeName(java.lang.String rowAssocTypeName)
Sets the base name string to be assigned to the topic which types the row associations generated if the convertRowInformation option is set to true.

Parameters:
rowAssocTypeName - the name assigned to the topic which is used to type associations generated for each row in the results set.

exportResultsSet

public void exportResultsSet(TologResultsSet rs)
                      throws TologFragmentBuilderException
Perform the export with the currently specified export parameters. This method will fail if setFragment() has not been called before calling this method.

Parameters:
rs - the tolog results set to be exported.
Throws:
TologFragmentBuilderException