Class Wrapper

java.lang.Object
fr.igred.omero.util.Wrapper

public final class Wrapper extends Object
Utility class to convert DataObjects dynamically.
  • Method Details

    • wrap

      public static <T extends ShapeData, U extends GenericShapeWrapper<? extends T>> U wrap(T object)
      Converts (wraps) a ShapeData object to a Shape object.
      Type Parameters:
      T - The ShapeData type.
      U - The Shape type.
      Parameters:
      object - The object to convert.
      Returns:
      See above.
    • wrap

      public static <T extends AnnotationData, U extends GenericAnnotationWrapper<? extends T>> U wrap(T object)
      Converts (wraps) an AnnotationData object to an Annotation object.
      Type Parameters:
      T - The AnnotationData type.
      U - The Annotation type.
      Parameters:
      object - The object to convert.
      Returns:
      See above.
    • wrapAnnotatableObject

      public static <T extends DataObject, U extends AnnotatableWrapper<? extends T>> U wrapAnnotatableObject(T object)
      Converts (wraps) a DataObject object to an Annotatable object.
      Type Parameters:
      T - The DataObject type.
      U - The Annotatable type.
      Parameters:
      object - The object to convert.
      Returns:
      See above.
    • wrapRepositoryObject

      public static <T extends DataObject, U extends GenericRepositoryObjectWrapper<? extends T>> U wrapRepositoryObject(T object)
      Converts (wraps) a DataObject object to a Repository object.
      Type Parameters:
      T - The DataObject type.
      U - The RepositoryObject type.
      Parameters:
      object - The object to convert.
      Returns:
      See above.
    • wrap

      public static <T extends DataObject, U extends GenericObjectWrapper<? extends T>> U wrap(T object)
      Converts (wraps) a DataObject to a GenericObjectWrapper.
      Type Parameters:
      T - The DataObject type.
      U - The RemoteObject type.
      Parameters:
      object - The object to convert.
      Returns:
      See above.