Class FieldDataFactory


  • public class FieldDataFactory
    extends java.lang.Object
    This class provides unique Reader and other field instances, when requested, based on an input RepositoryDocument. It does this by pulling the values of the field into a CharacterInput implementation, thus making a temporary file copy. So it is imperative that this object is closed when it is no longer needed.
    • Field Summary

      Fields 
      Modifier and Type Field Description
      protected java.util.Map<java.lang.String,​org.apache.manifoldcf.core.interfaces.CharacterInput[]> metadataReaders  
      protected org.apache.manifoldcf.agents.interfaces.RepositoryDocument sourceDocument  
    • Constructor Summary

      Constructors 
      Constructor Description
      FieldDataFactory​(org.apache.manifoldcf.agents.interfaces.RepositoryDocument sourceDocument)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void close()  
      java.lang.Object[] getField​(java.lang.String fieldName)  
      java.lang.String[] getFieldAsStrings​(java.lang.String fieldName)  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • sourceDocument

        protected final org.apache.manifoldcf.agents.interfaces.RepositoryDocument sourceDocument
      • metadataReaders

        protected final java.util.Map<java.lang.String,​org.apache.manifoldcf.core.interfaces.CharacterInput[]> metadataReaders
    • Constructor Detail

      • FieldDataFactory

        public FieldDataFactory​(org.apache.manifoldcf.agents.interfaces.RepositoryDocument sourceDocument)
    • Method Detail

      • close

        public void close()
                   throws org.apache.manifoldcf.core.interfaces.ManifoldCFException
        Throws:
        org.apache.manifoldcf.core.interfaces.ManifoldCFException
      • getField

        public java.lang.Object[] getField​(java.lang.String fieldName)
                                    throws java.io.IOException,
                                           org.apache.manifoldcf.core.interfaces.ManifoldCFException
        Throws:
        java.io.IOException
        org.apache.manifoldcf.core.interfaces.ManifoldCFException
      • getFieldAsStrings

        public java.lang.String[] getFieldAsStrings​(java.lang.String fieldName)
                                             throws java.io.IOException,
                                                    org.apache.manifoldcf.core.interfaces.ManifoldCFException
        Throws:
        java.io.IOException
        org.apache.manifoldcf.core.interfaces.ManifoldCFException