Packages

 

com.aspose.cad.fileformats.cad

Class CadImage

    • Field Detail

      • FilePath_internalized

        public String FilePath_internalized

        File path.

    • Constructor Detail

      • CadImage

        public CadImage()

        Initializes a new instance of the CadImage class.

    • Method Detail

      • getCadImageType_internalized

        public int getCadImageType_internalized()
      • setCadImageType_internalized

        public void setCadImageType_internalized(int value)

        Gets or sets type of image.

      • getLineTypes

        public CadLineTypesDictionary getLineTypes()

        Gets or sets the dimension styles.

        Value: The dimension styles.
      • setLineTypes

        public void setLineTypes(CadLineTypesDictionary value)

        Gets or sets the dimension styles.

        Value: The dimension styles.
      • getBitsPerPixel

        public int getBitsPerPixel()

        Gets the image bits per pixel count.

        Value: The image bits per pixel count.
        Specified by:
        getBitsPerPixel in class Image
      • getBlockEntities

        public CadBlockDictionary getBlockEntities()

        Gets or sets the block entities.

        Value: The block entities.
      • setBlockEntities

        public void setBlockEntities(CadBlockDictionary value)

        Gets or sets the block entities.

        Value: The block entities.
      • getClassEntities

        public CadClassDictionary getClassEntities()

        Gets or sets the class entities.

        Value: The class entities.
      • setClassEntities

        public void setClassEntities(CadClassDictionary value)

        Gets or sets the class entities.

        Value: The class entities.
      • getBlocksTables

        public CadBlockRecordList getBlocksTables()

        Gets or sets the blocks tables.

        Value: The blocks tables.
      • setBlocksTables

        public void setBlocksTables(CadBlockRecordList value)

        Gets or sets the blocks tables.

        Value: The blocks tables.
      • getDimensionStyles

        public CadDimensionDictionary getDimensionStyles()

        Gets or sets the dimension styles.

        Value: The dimension styles.
      • setDimensionStyles

        public void setDimensionStyles(CadDimensionDictionary value)

        Gets or sets the dimension styles.

        Value: The dimension styles.
      • getEntities

        public CadBaseEntity[] getEntities()

        Gets or sets the entities.

        Value: The entities.
      • setEntities

        public void setEntities(CadBaseEntity[] value)

        Gets or sets the entities.

        Value: The entities.
      • getObjects

        public CadBaseObject[] getObjects()

        Gets or sets the objects.

        Throws:
        CadException - Invalid value for Objects Value: The objects.
      • setObjects

        public void setObjects(CadBaseObject[] value)

        Gets or sets the objects.

        Throws:
        CadException - Invalid value for Objects Value: The objects.
      • isCached

        public final boolean isCached()

        Gets a value indicating whether object's data is cached currently and no data reading is required.

        Value: true if object's data is cached; otherwise, false.
        Specified by:
        isCached in class DataStreamSupporter
      • getLayers

        public CadLayersDictionary getLayers()

        Gets or sets the layers.

        Value: The layers.
      • setLayers

        public void setLayers(CadLayersDictionary value)

        Gets or sets the layers.

        Value: The layers.
      • getMaxPoint

        public Cad3DPoint getMaxPoint()

        Gets the max point.

      • getMinPoint

        public Cad3DPoint getMinPoint()

        Gets the min point.

      • getStyles

        public CadStylesList getStyles()

        Gets or sets the styles.

      • setStyles

        public void setStyles(CadStylesList value)

        Gets or sets the styles.

      • getHeader

        public CadHeader getHeader()

        Gets or sets the header.

        Value: The header.
      • setHeader

        public void setHeader(CadHeader value)

        Gets or sets the header.

        Value: The header.
      • getViewPorts

        public CadVportList getViewPorts()

        Gets or sets the view ports.

        Value: The view ports.
      • setViewPorts

        public void setViewPorts(CadVportList value)

        Gets or sets the view ports.

        Value: The view ports.
      • getViews

        public CadViewList getViews()

        Gets or sets the views.

        Value: The views.
      • setViews

        public void setViews(CadViewList value)

        Gets or sets the views.

        Value: The views.
      • getUCSs

        public CadUcsList getUCSs()

        Gets or sets the uc ss.

        Value: The uc ss.
      • setUCSs

        public void setUCSs(CadUcsList value)

        Gets or sets the uc ss.

        Value: The uc ss.
      • getAppIdTables

        public CadAppIdDictionary getAppIdTables()

        Gets or sets the application identifier tables.

        Value: The application identifier tables.
      • setAppIdTables

        public void setAppIdTables(CadAppIdDictionary value)

        Gets or sets the application identifier tables.

        Value: The application identifier tables.
      • removeEntityAt

        public void removeEntityAt(int position)

        Removes entity by its position.

        Parameters:
        position - Position to remove entity from.
      • removeEntity

        public void removeEntity(CadBaseEntity entity)

        Removes enity.

        Parameters:
        entity - Entity to remove.
      • cacheData

        public final void cacheData()

        Caches the data and ensures no additional data loading will be performed from the underlying DataStreamSupporter.DataStreamContainer.

        Specified by:
        cacheData in class DataStreamSupporter
      • resize

        public void resize(int newWidth,
                           int newHeight,
                           int resizeType)

        Resizes the image.

        Specified by:
        resize in class Image
        Parameters:
        newWidth - The new width.
        newHeight - The new height.
        resizeType - The resize type.
      • resize

        public void resize(int newWidth,
                           int newHeight,
                           ImageResizeSettings settings)

        Resizes the image.

        Specified by:
        resize in class Image
        Parameters:
        newWidth - The new width.
        newHeight - The new height.
        settings - The resize settings.
      • rotateFlip

        public void rotateFlip(int rotateFlipType)

        Rotates, flips, or rotates and flips the image.

        Specified by:
        rotateFlip in class Image
        Parameters:
        rotateFlipType - Type of the rotate flip.
      • setPalette

        public void setPalette(IColorPalette palette,
                               boolean updateColors)

        Sets the image palette.

        Specified by:
        setPalette in class Image
        Parameters:
        palette - The palette to set.
        updateColors - if set to true colors will be updated according to the new palette; otherwise color indexes remain unchanged. Note that unchanged indexes may crash the image on loading if some indexes have no corresponding palette entries.
      • updateSize

        public void updateSize()

        Updates size of an image after changes, that may affect initial size, e.g. removing of entities. MinPoint, MaxPoint, Width and Height properties of image are updated.

      • getCadParameterTypeString

        public static String getCadParameterTypeString(CadParameter parameter)

        Gets the cad parameter type string.

        Parameters:
        parameter - The parameter.
        Returns:
        Parameter type as string
      • getStringValueWithSuffix

        public static String getStringValueWithSuffix(String value,
                                                      int countSymbols)

        Gets the string value with suffix.

        Parameters:
        value - The value.
        countSymbols - The count symbols.
        Returns:
        String value with suffix
      • getStringValue

        public static String getStringValue(CadParameter value)

        Gets the string value for cad parameter

        Parameters:
        value - The cad value.
        Returns:
        string value
      • setUnit_internalized

        public void setUnit_internalized()

        Sets unit type for DXF/DWG formats.

      • setSize_internalized

        public void setSize_internalized()

        Gets or sets size of an image