Class RegionExportFactorXML

java.lang.Object
fr.ifremer.isisfish.mexico.export.RegionExportFactorXML
All Implemented Interfaces:
RegionExport, org.nuiton.topia.persistence.EntityVisitor

public class RegionExportFactorXML extends Object implements RegionExport
Export implementation for factor into xml.
Version:
$Revision$ Last update : $Date$ By : $Author$
Author:
chatellier
  • Field Details

    • outputFile

      protected File outputFile
    • stringBuffer

      protected StringBuffer stringBuffer
    • lastReadName

      protected String lastReadName
  • Constructor Details

    • RegionExportFactorXML

      public RegionExportFactorXML(File outputFile)
  • Method Details

    • beginExport

      public void beginExport()
      Description copied from interface: RegionExport
      Called at export begin.
      Specified by:
      beginExport in interface RegionExport
    • start

      public void start(org.nuiton.topia.persistence.TopiaEntity entity)
      Specified by:
      start in interface org.nuiton.topia.persistence.EntityVisitor
    • visit

      public void visit(org.nuiton.topia.persistence.TopiaEntity entity, String propertyName, Class<?> type, Object value)
      Specified by:
      visit in interface org.nuiton.topia.persistence.EntityVisitor
    • visit

      public void visit(org.nuiton.topia.persistence.TopiaEntity entity, String propertyName, Class<?> collectionType, Class<?> type, Object value)
      Specified by:
      visit in interface org.nuiton.topia.persistence.EntityVisitor
    • visit

      public void visit(org.nuiton.topia.persistence.TopiaEntity entity, String propertyName, Class<?> collectionType, Class<?> type, int index, Object value)
      Specified by:
      visit in interface org.nuiton.topia.persistence.EntityVisitor
    • end

      public void end(org.nuiton.topia.persistence.TopiaEntity entity)
      Specified by:
      end in interface org.nuiton.topia.persistence.EntityVisitor
    • clear

      public void clear()
      Specified by:
      clear in interface org.nuiton.topia.persistence.EntityVisitor
    • endExport

      public void endExport()
      Description copied from interface: RegionExport
      Called at export end.
      Specified by:
      endExport in interface RegionExport
    • getUniqueFactorName

      protected String getUniqueFactorName(org.nuiton.topia.persistence.TopiaEntity entity, String factorClass, String propertyName)
      Get factor name. Dans la majorité des cas, on a un lastReadName défini. Dans les autre cas, il faut chercher un meilleur nom.
      Parameters:
      entity - entity to get factor name
      factorClass - entity short class name
      propertyName - property name
      Returns:
      unique name for factor
    • getStringValue

      protected String getStringValue(org.nuiton.topia.persistence.TopiaEntity entity, Class<?> type, Object value)
      Get string value.
      Parameters:
      entity - entity
      type - value type
      value - value