Klasse ProductFileUtil

java.lang.Object
de.dlr.proseo.ingestor.rest.model.ProductFileUtil

public class ProductFileUtil extends Object
Utility methods for product files, e. g. for conversion between prosEO model and REST model
Autor:
Dr. Thomas Bassler
  • Konstruktordetails

    • ProductFileUtil

      public ProductFileUtil()
  • Methodendetails

    • toRestProductFile

      public static RestProductFile toRestProductFile(ProductFile modelProductFile)
      Convert a prosEO model product file into a REST product file
      Parameter:
      modelProductFile - the prosEO model product
      Gibt zurück:
      an equivalent REST product or null, if no model product was given
    • toModelProductFile

      public static ProductFile toModelProductFile(RestProductFile restProductFile) throws IllegalArgumentException
      Convert a REST product file into a prosEO model product file (scalar and embedded attributes only, no product references)
      Parameter:
      restProductFile - the REST product
      Gibt zurück:
      a (roughly) equivalent model product or null, if no REST product was given
      Löst aus:
      IllegalArgumentException - if the REST product violates syntax rules for date, enum or numeric values