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.
    • Constructor Detail

      • TemplateReaderWriter

        public TemplateReaderWriter()
        Deprecated.
    • Method Detail

      • read

        public TemplatePersistenceData[] read​(Reader reader)
                                       throws 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:
        IOException - if reading from the stream fails
      • readSingle

        public TemplatePersistenceData readSingle​(Reader reader,
                                                  String id)
                                           throws 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:
        IOException - if reading from the stream fails
      • read

        public TemplatePersistenceData[] read​(Reader reader,
                                              ResourceBundle bundle)
                                       throws 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:
        IOException - if reading from the stream fails
      • read

        public TemplatePersistenceData[] read​(InputStream stream,
                                              ResourceBundle bundle)
                                       throws 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:
        IOException - if reading from the stream fails