Klasse Data

java.lang.Object
org.deidentifier.arx.Data
Bekannte direkte Unterklassen:
Data.DefaultData

public abstract class Data extends Object
Represents input data for the ARX framework.
  • Konstruktordetails

    • Data

      public Data()
  • Methodendetails

    • create

      public static Data.DefaultData create()
      Creates a new default data object.
      Gibt zurück:
      A Data object
    • create

      public static Data create(DataSource source) throws IOException
      Creates a new data object from the given data source specification.
      Parameter:
      source - The source that should be used to import data
      Gibt zurück:
      Data object as described by the data source
      Löst aus:
      IOException - Signals that an I/O exception has occurred.
    • create

      public static Data create(File file, Charset charset) throws IOException
      Creates a new data object from a CSV file. Assumes that the file contains a header.
      Parameter:
      file - the file
      Gibt zurück:
      the data
      Löst aus:
      IOException - Signals that an I/O exception has occurred.
    • create

      public static Data create(File file, Charset charset, char delimiter) throws IOException
      Creates a new data object from a CSV file. Assumes that the file contains a header.
      Parameter:
      file - A file
      delimiter - The utilized separator character
      Gibt zurück:
      A Data object
      Löst aus:
      IOException - Signals that an I/O exception has occurred.
    • create

      public static Data create(File file, Charset charset, char delimiter, char quote) throws IOException
      Creates a new data object from a CSV file. Assumes that the file contains a header.
      Parameter:
      file - A file
      delimiter - The utilized separator character
      quote - The delimiter for strings
      Gibt zurück:
      A Data object
      Löst aus:
      IOException - Signals that an I/O exception has occurred.
    • create

      public static Data create(File file, Charset charset, char delimiter, char quote, char escape) throws IOException
      Creates a new data object from a CSV file. Assumes that the file contains a header.
      Parameter:
      file - the file
      delimiter - the delimiter
      quote - the quote
      escape - the escape
      Gibt zurück:
      the data
      Löst aus:
      IOException - Signals that an I/O exception has occurred.
    • create

      public static Data create(File file, Charset charset, char delimiter, char quote, char escape, char[] linebreak) throws IOException
      Creates a new data object from a CSV file. Assumes that the file contains a header.
      Parameter:
      file - the file
      delimiter - the delimiter
      quote - the quote
      escape - the escape
      linebreak - the linebreak
      Gibt zurück:
      the data
      Löst aus:
      IOException - Signals that an I/O exception has occurred.
    • create

      public static Data create(File file, Charset charset, CSVSyntax config) throws IOException
      Creates a new data object from a CSV file. Assumes that the file contains a header.
      Parameter:
      file - the file
      config - the config
      Gibt zurück:
      the data
      Löst aus:
      IOException - Signals that an I/O exception has occurred.
    • create

      public static Data create(File file, Charset charset, CSVSyntax config, CSVOptions options) throws IOException
      Creates a new data object from a CSV file. Assumes that the file contains a header.
      Parameter:
      file - the file
      config - the config
      options - the options
      Gibt zurück:
      the data
      Löst aus:
      IOException - Signals that an I/O exception has occurred.
    • create

      public static Data create(File file, Charset charset, CSVSyntax config, DataType<?>[] datatypes) throws IOException
      Creates a new data object from a CSV file. Assumes that the file contains a header.
      Parameter:
      file - the file
      config - the config
      datatypes - the datatypes
      Gibt zurück:
      the data
      Löst aus:
      IOException - Signals that an I/O exception has occurred.
    • create

      public static Data create(InputStream stream, Charset charset) throws IOException
      Creates a new data object from a CSV file. Assumes that the file contains a header.
      Parameter:
      stream - the stream
      Gibt zurück:
      the data
      Löst aus:
      IOException - Signals that an I/O exception has occurred.
    • create

      public static Data create(InputStream stream, Charset charset, char delimiter) throws IOException
      Creates a new data object from a CSV file. Assumes that the file contains a header.
      Parameter:
      stream - An input stream
      delimiter - The utilized separator character
      Gibt zurück:
      A Data object
      Löst aus:
      IOException - Signals that an I/O exception has occurred.
    • create

      public static Data create(InputStream stream, Charset charset, char delimiter, int length) throws IOException
      Creates a new data object from a CSV file. Assumes that the file contains a header.
      Parameter:
      stream - An input stream
      delimiter - The utilized separator character
      length - For improved memory requirements
      Gibt zurück:
      A Data object
      Löst aus:
      IOException - Signals that an I/O exception has occurred.
    • create

      public static Data create(InputStream stream, Charset charset, char delimiter, char quote) throws IOException
      Creates a new data object from a CSV file. Assumes that the file contains a header.
      Parameter:
      stream - An input stream
      delimiter - The utilized separator character
      quote - The delimiter for strings
      Gibt zurück:
      A Data object
      Löst aus:
      IOException - Signals that an I/O exception has occurred.
    • create

      public static Data create(InputStream stream, Charset charset, char delimiter, char quote, char escape) throws IOException
      Creates a new data object from a CSV file. Assumes that the file contains a header.
      Parameter:
      stream - the stream
      delimiter - the delimiter
      quote - the quote
      escape - the escape
      Gibt zurück:
      the data
      Löst aus:
      IOException - Signals that an I/O exception has occurred.
    • create

      public static Data create(InputStream stream, Charset charset, char delimiter, char quote, char escape, char[] linebreak) throws IOException
      Creates a new data object from a CSV file. Assumes that the file contains a header.
      Parameter:
      stream - the stream
      delimiter - the delimiter
      quote - the quote
      escape - the escape
      linebreak - the linebreak
      Gibt zurück:
      the data
      Löst aus:
      IOException - Signals that an I/O exception has occurred.
    • create

      public static Data create(InputStream stream, Charset charset, CSVSyntax config) throws IOException
      Creates a new data object from a CSV file. Assumes that the file contains a header.
      Parameter:
      stream - the stream
      config - the config
      Gibt zurück:
      the data
      Löst aus:
      IOException - Signals that an I/O exception has occurred.
    • create

      public static Data create(InputStream stream, Charset charset, CSVSyntax config, DataType<?>[] datatypes) throws IOException
      Creates a new data object from a CSV file. Assumes that the file contains a header.
      Parameter:
      stream - the stream
      config - the config
      datatypes - the datatypes
      Gibt zurück:
      the data
      Löst aus:
      IOException - Signals that an I/O exception has occurred.
    • create

      public static Data create(Iterator<String[]> iterator)
      Creates a new data object from an iterator over tuples.
      Parameter:
      iterator - An iterator
      Gibt zurück:
      A Data object
    • create

      public static Data create(Iterator<String[]> iterator, Integer length)
      Creates a new data object from an iterator over tuples.
      Parameter:
      iterator - An iterator
      length - number of records to load
      Gibt zurück:
      A data object
    • create

      public static Data create(List<String[]> list)
      Creates a new data object from a list.
      Parameter:
      list - The list
      Gibt zurück:
      A Data object
    • create

      public static Data create(String path, Charset charset) throws IOException
      Creates a new data object from a CSV file. Assumes that the file contains a header.
      Parameter:
      path - the path
      Gibt zurück:
      the data
      Löst aus:
      IOException - Signals that an I/O exception has occurred.
    • create

      public static Data create(String path, Charset charset, char delimiter) throws IOException
      Creates a new data object from a CSV file. Assumes that the file contains a header.
      Parameter:
      path - A path to the file
      delimiter - The utilized separator character
      Gibt zurück:
      A Data object
      Löst aus:
      IOException - Signals that an I/O exception has occurred.
    • create

      public static Data create(String path, Charset charset, char delimiter, char quote) throws IOException
      Creates a new data object from a CSV file. Assumes that the file contains a header.
      Parameter:
      path - A path to the file
      delimiter - The utilized separator character
      quote - The delimiter for strings
      Gibt zurück:
      A Data object
      Löst aus:
      IOException - Signals that an I/O exception has occurred.
    • create

      public static Data create(String path, Charset charset, char delimiter, char quote, char escape) throws IOException
      Creates a new data object from a CSV file. Assumes that the file contains a header.
      Parameter:
      path - the path
      delimiter - the delimiter
      quote - the quote
      escape - the escape
      Gibt zurück:
      the data
      Löst aus:
      IOException - Signals that an I/O exception has occurred.
    • create

      public static Data create(String path, Charset charset, char delimiter, char quote, char escape, char[] linebreak) throws IOException
      Creates a new data object from a CSV file. Assumes that the file contains a header.
      Parameter:
      path - the path
      delimiter - the delimiter
      quote - the quote
      escape - the escape
      linebreak - the linebreak
      Gibt zurück:
      the data
      Löst aus:
      IOException - Signals that an I/O exception has occurred.
    • create

      public static Data create(String path, Charset charset, CSVSyntax config, CSVOptions options) throws IOException
      Creates a new data object from a CSV file. Assumes that the file contains a header.
      Parameter:
      path - the path
      config - the config
      options - the options
      Gibt zurück:
      the data
      Löst aus:
      IOException - Signals that an I/O exception has occurred.
    • create

      public static Data create(String path, Charset charset, CSVSyntax config, DataType<?>[] datatypes) throws IOException
      Creates a new data object from a CSV file. Assumes that the file contains a header.
      Parameter:
      path - the path
      config - the config
      datatypes - the datatypes
      Gibt zurück:
      the data
      Löst aus:
      IOException - Signals that an I/O exception has occurred.
    • create

      public static Data create(String[][] array)
      Creates a new data object from a two-dimensional string array.
      Parameter:
      array - The array
      Gibt zurück:
      A Data object
    • getDefinition

      public DataDefinition getDefinition()
      Returns the data definition.
      Gibt zurück:
      the definition
    • getHandle

      public DataHandle getHandle()
      Returns a data handle.
      Gibt zurück:
      the handle
    • getLength

      protected Integer getLength()
      Override to return a length to improve loading
      Gibt zurück:
    • iterator

      protected abstract Iterator<String[]> iterator()
      Iterator.
      Gibt zurück:
      the iterator