Class S73DHelper


  • public class S73DHelper
    extends Object
    • Constructor Detail

      • S73DHelper

        public S73DHelper()
    • Method Detail

      • isV3DInstalled

        public static boolean isV3DInstalled​(Session session)
      • getS7Type

        public static String getS7Type​(Resource resource)
        Returns the S7 type for the given resource.
        Parameters:
        resource - resource instance
        Returns:
        the S7 type or null if the type is missing
      • isS73D

        public static boolean isS73D​(Resource resource)
        Checks whether the given resource represent an S7 3D model or not.
        Parameters:
        resource - resource instance
        Returns:
        true if the resource is marked as a 3D resource, false otherwise
      • hasModel

        public static boolean hasModel​(Resource resource)
        Does the resource contain a model folder - indicating 3D ingestion has been applied
        Parameters:
        resource - resource instance
        Returns:
        true if a model directory exists, otherwise false
      • is3DMimeType

        public static boolean is3DMimeType​(Resource resource)
        Checks whether the given resource represent an S7 3D model or not.
        Parameters:
        resource - resource instance
        Returns:
        true if the resource is marked as a 3D resource, false otherwise
      • getDependencyPaths

        public static String[] getDependencyPaths​(Resource resource)
        Get a list of dependencies.
        Parameters:
        resource - resource instance
        Returns:
        a string array of dependency paths or null if not 3D or no dependencies
      • isUnResolved

        public static boolean isUnResolved​(Resource resource)
        Does the resource have unresolved dependencies
        Parameters:
        resource - resource instance
        Returns:
        true if a 3D resource with unresolved dependencies, otherwise false
      • isIncomplete

        public static boolean isIncomplete​(Resource resource)
        Does the resource have unresolved required dependencies
        Parameters:
        resource - resource instance
        Returns:
        true if a 3D resource with unresolved dependencies, otherwise false
      • getProgressValue

        public static String getProgressValue​(Resource resource)
        Returns the progress value for the given resource
        Parameters:
        resource - resource instance
        Returns:
        percentage string if the resource represent a S7 model and has a progress value empty string otherwise
      • getProgressOperation

        public static String getProgressOperation​(Resource resource)
        Returns the progress operation for the given resource
        Parameters:
        resource - resource instance
        Returns:
        operation string if the resource represent a S7 model and has a progress value empty string otherwise
      • has3DMimeTypeDC

        public static boolean has3DMimeTypeDC​(Resource resource)
        Returns true if the metadata based mime type is recognized as a 3D resource - uses DC_FORMAT
        Parameters:
        resource - resource
        Returns:
        true if set to 3D mime type, false if not
      • has3DMimeTypeJCR

        public static boolean has3DMimeTypeJCR​(Resource resource)
        Returns true if the metadata based mime type is recognized as a 3D resource - uses JCR_FORMAT
        Parameters:
        resource - resource
        Returns:
        true if set to 3D mime type, false if not
      • get3DMimeType

        public static String get3DMimeType​(Asset asset)
        Returns the mime type string for a 3D asset
        Parameters:
        asset - asset
        Returns:
        mime type string if 3D asset or null if not
      • get3DMimeType

        public static String get3DMimeType​(String fileName)
        Returns the mime type string for an asset or file path based on the extension
        Parameters:
        fileName - filename
        Returns:
        mime type string if recognized 3D extension or null if not