Class TemplateReaderWriter


  • @Deprecated
    public class TemplateReaderWriter
    extends org.eclipse.text.templates.TemplateReaderWriter
    Deprecated.
    See TemplateReaderWriter
    Serializes templates as character or byte stream and reads the same format back.

    Clients may instantiate this class, it is not intended to be subclassed.

    Since:
    3.0
    Restriction:
    This class is not intended to be subclassed by clients.
    • Method Summary

      All Methods Instance Methods Concrete Methods Deprecated Methods 
      Modifier and Type Method Description
      TemplatePersistenceData[] read​(java.io.InputStream stream, java.util.ResourceBundle bundle)
      Deprecated.
      Reads templates from a stream and adds them to the templates.
      TemplatePersistenceData[] read​(java.io.Reader reader)
      Deprecated.
      Reads templates from a reader and returns them.
      TemplatePersistenceData[] read​(java.io.Reader reader, java.util.ResourceBundle bundle)
      Deprecated.
      Reads templates from a stream and adds them to the templates.
      TemplatePersistenceData readSingle​(java.io.Reader reader, java.lang.String id)
      Deprecated.
      Reads the template with identifier id from a reader and returns it.
      void save​(TemplatePersistenceData[] templates, java.io.OutputStream stream)
      Deprecated.
       
      void save​(TemplatePersistenceData[] templates, java.io.Writer writer)
      Deprecated.
       
      • Methods inherited from class org.eclipse.text.templates.TemplateReaderWriter

        save, save
      • Methods inherited from class java.lang.Object

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

      • TemplateReaderWriter

        public TemplateReaderWriter()
        Deprecated.
    • Method Detail

      • read

        public TemplatePersistenceData[] read​(java.io.Reader reader)
                                       throws java.io.IOException
        Deprecated.
        Description copied from class: org.eclipse.text.templates.TemplateReaderWriter
        Reads templates from a reader and returns them. The reader must present a serialized form as produced by the save method.
        Overrides:
        read in class org.eclipse.text.templates.TemplateReaderWriter
        Parameters:
        reader - the reader to read templates from
        Returns:
        the read templates, encapsulated in instances of TemplatePersistenceData
        Throws:
        java.io.IOException - if reading from the stream fails
      • readSingle

        public TemplatePersistenceData readSingle​(java.io.Reader reader,
                                                  java.lang.String id)
                                           throws java.io.IOException
        Deprecated.
        Description copied from class: org.eclipse.text.templates.TemplateReaderWriter
        Reads the template with identifier id from a reader and returns it. The reader must present a serialized form as produced by the save method.
        Overrides:
        readSingle in class org.eclipse.text.templates.TemplateReaderWriter
        Parameters:
        reader - the reader to read templates from
        id - the id of the template to return
        Returns:
        the read template, encapsulated in an instances of TemplatePersistenceData
        Throws:
        java.io.IOException - if reading from the stream fails
      • read

        public TemplatePersistenceData[] read​(java.io.Reader reader,
                                              java.util.ResourceBundle bundle)
                                       throws java.io.IOException
        Deprecated.
        Description copied from class: org.eclipse.text.templates.TemplateReaderWriter
        Reads templates from a stream and adds them to the templates.
        Overrides:
        read in class org.eclipse.text.templates.TemplateReaderWriter
        Parameters:
        reader - the reader to read templates from
        bundle - a resource bundle to use for translating the read templates, or null if no translation should occur
        Returns:
        the read templates, encapsulated in instances of TemplatePersistenceData
        Throws:
        java.io.IOException - if reading from the stream fails
      • read

        public TemplatePersistenceData[] read​(java.io.InputStream stream,
                                              java.util.ResourceBundle bundle)
                                       throws java.io.IOException
        Deprecated.
        Description copied from class: org.eclipse.text.templates.TemplateReaderWriter
        Reads templates from a stream and adds them to the templates.
        Overrides:
        read in class org.eclipse.text.templates.TemplateReaderWriter
        Parameters:
        stream - the byte stream to read templates from
        bundle - a resource bundle to use for translating the read templates, or null if no translation should occur
        Returns:
        the read templates, encapsulated in instances of TemplatePersistenceData
        Throws:
        java.io.IOException - if reading from the stream fails
      • save

        public void save​(TemplatePersistenceData[] templates,
                         java.io.OutputStream stream)
                  throws java.io.IOException
        Deprecated.
        Throws:
        java.io.IOException
      • save

        public void save​(TemplatePersistenceData[] templates,
                         java.io.Writer writer)
                  throws java.io.IOException
        Deprecated.
        Throws:
        java.io.IOException