Package system.drawing
Class Image
- java.lang.Object
-
- org.mases.jcobridge.netreflection.NetObject
-
- system.MarshalByRefObject
-
- system.drawing.Image
-
- All Implemented Interfaces:
AutoCloseable
,IJCOBridgeReflected
,ISerializable
public class Image extends MarshalByRefObject implements ISerializable, AutoCloseable
The base .NET class managing System.Drawing.Image, System.Drawing.Common, Version=6.0.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51.See: https://docs.microsoft.com/en-us/dotnet/api/System.Drawing.Image
-
-
Field Summary
Fields Modifier and Type Field Description static String
assemblyFullName
Fully assembly qualified name: System.Drawing.Common, Version=6.0.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51static String
assemblyShortName
Assembly name: System.Drawing.Commonstatic String
className
Qualified class name: System.Drawing.Imagestatic JCType
classType
The type managed from JCOBridge.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description static Image
cast(IJCOBridgeReflected from)
Try to cast theIJCOBridgeReflected
instance intoImage
, a cast assert is made to check if types are compatible.NetObject
Clone()
void
close()
void
Dispose()
static Image
FromFile(String filename)
static Image
FromFile(String filename, boolean useEmbeddedColorManagement)
static Image
FromStream(Stream stream)
static Image
FromStream(Stream stream, boolean useEmbeddedColorManagement)
static Image
FromStream(Stream stream, boolean useEmbeddedColorManagement, boolean validateImageData)
RectangleF
GetBounds(JCORefOut<GraphicsUnit> pageUnit)
EncoderParameters
GetEncoderParameterList(Guid encoder)
int
getFlags()
int
GetFrameCount(FrameDimension dimension)
Guid[]
getFrameDimensionsList()
int
getHeight()
Single
getHorizontalResolution()
String
getJCOAssemblyName()
Returns the reflected Assembly nameString
getJCOClassName()
Returns the reflected Class nameObject
getJCOInstance()
Returns the instantiated classString
getJCOObjectName()
Returns the reflected Class name used to build the objectJCType
getJCOType()
Returns the instantiated class Typevoid
GetObjectData(SerializationInfo info, StreamingContext context)
Deprecated.Not for public use because the method is implemented in .NET with an explicit interface.ColorPalette
getPalette()
SizeF
getPhysicalDimension()
PixelFormat
getPixelFormat()
static int
GetPixelFormatSize(PixelFormat pixfmt)
int[]
getPropertyIdList()
PropertyItem
GetPropertyItem(int propid)
PropertyItem[]
getPropertyItems()
ImageFormat
getRawFormat()
Size
getSize()
NetObject
getTag()
Single
getVerticalResolution()
int
getWidth()
static boolean
IsAlphaPixelFormat(PixelFormat pixfmt)
static boolean
IsCanonicalPixelFormat(PixelFormat pixfmt)
static boolean
IsExtendedPixelFormat(PixelFormat pixfmt)
void
RemovePropertyItem(int propid)
void
RotateFlip(RotateFlipType rotateFlipType)
void
Save(String filename)
void
Save(String filename, ImageCodecInfo encoder, EncoderParameters encoderParams)
void
Save(String filename, ImageFormat format)
void
Save(Stream stream, ImageCodecInfo encoder, EncoderParameters encoderParams)
void
Save(Stream stream, ImageFormat format)
void
SaveAdd(Image image, EncoderParameters encoderParams)
void
SaveAdd(EncoderParameters encoderParams)
int
SelectActiveFrame(FrameDimension dimension, int frameIndex)
void
setJCOInstance(JCObject instance)
void
setPalette(ColorPalette Palette)
void
SetPropertyItem(PropertyItem propitem)
void
setTag(NetObject Tag)
-
Methods inherited from class system.MarshalByRefObject
GetLifetimeService, InitializeLifetimeService
-
Methods inherited from class org.mases.jcobridge.netreflection.NetObject
Equals, Equals, GetHashCode, GetType, hashCode, toObjectFromArray, toObjectFromArray, toString, ToString, translateException
-
-
-
-
Field Detail
-
assemblyFullName
public static final String assemblyFullName
Fully assembly qualified name: System.Drawing.Common, Version=6.0.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51- See Also:
- Constant Field Values
-
assemblyShortName
public static final String assemblyShortName
Assembly name: System.Drawing.Common- See Also:
- Constant Field Values
-
className
public static final String className
Qualified class name: System.Drawing.Image- See Also:
- Constant Field Values
-
-
Method Detail
-
getJCOAssemblyName
public String getJCOAssemblyName()
Description copied from interface:IJCOBridgeReflected
Returns the reflected Assembly name- Specified by:
getJCOAssemblyName
in interfaceIJCOBridgeReflected
- Specified by:
getJCOAssemblyName
in interfaceISerializable
- Overrides:
getJCOAssemblyName
in classMarshalByRefObject
- Returns:
- A
String
representing the Fullname of reflected Assembly
-
getJCOClassName
public String getJCOClassName()
Description copied from interface:IJCOBridgeReflected
Returns the reflected Class name- Specified by:
getJCOClassName
in interfaceIJCOBridgeReflected
- Specified by:
getJCOClassName
in interfaceISerializable
- Overrides:
getJCOClassName
in classMarshalByRefObject
- Returns:
- A
String
representing the Fullname of reflected Class
-
getJCOObjectName
public String getJCOObjectName()
Description copied from interface:IJCOBridgeReflected
Returns the reflected Class name used to build the object- Specified by:
getJCOObjectName
in interfaceIJCOBridgeReflected
- Specified by:
getJCOObjectName
in interfaceISerializable
- Overrides:
getJCOObjectName
in classMarshalByRefObject
- Returns:
- A
String
representing the name used to allocated the object in CLR context
-
getJCOInstance
public Object getJCOInstance()
Description copied from interface:IJCOBridgeReflected
Returns the instantiated class- Specified by:
getJCOInstance
in interfaceIJCOBridgeReflected
- Specified by:
getJCOInstance
in interfaceISerializable
- Overrides:
getJCOInstance
in classMarshalByRefObject
- Returns:
- An
Object
representing the CLR instance of the instantiated Class
-
setJCOInstance
public void setJCOInstance(JCObject instance)
- Overrides:
setJCOInstance
in classMarshalByRefObject
-
getJCOType
public JCType getJCOType()
Description copied from interface:IJCOBridgeReflected
Returns the instantiated class Type- Specified by:
getJCOType
in interfaceIJCOBridgeReflected
- Specified by:
getJCOType
in interfaceISerializable
- Overrides:
getJCOType
in classMarshalByRefObject
- Returns:
- A
JCType
representing the CLR Type of the instantiated Class
-
cast
public static Image cast(IJCOBridgeReflected from) throws Throwable
Try to cast theIJCOBridgeReflected
instance intoImage
, a cast assert is made to check if types are compatible.- Parameters:
from
-IJCOBridgeReflected
instance to be casted- Returns:
Image
instance- Throws:
Throwable
- in case of error during cast operation
-
IsAlphaPixelFormat
public static boolean IsAlphaPixelFormat(PixelFormat pixfmt) throws Throwable
- Throws:
Throwable
-
IsCanonicalPixelFormat
public static boolean IsCanonicalPixelFormat(PixelFormat pixfmt) throws Throwable
- Throws:
Throwable
-
IsExtendedPixelFormat
public static boolean IsExtendedPixelFormat(PixelFormat pixfmt) throws Throwable
- Throws:
Throwable
-
GetFrameCount
public int GetFrameCount(FrameDimension dimension) throws Throwable, ArgumentNullException, ArgumentException, CultureNotFoundException, ObjectDisposedException, InvalidOperationException, ArrayTypeMismatchException, PlatformNotSupportedException, ArgumentOutOfRangeException, IndexOutOfRangeException
-
GetPixelFormatSize
public static int GetPixelFormatSize(PixelFormat pixfmt) throws Throwable
- Throws:
Throwable
-
SelectActiveFrame
public int SelectActiveFrame(FrameDimension dimension, int frameIndex) throws Throwable, ArgumentNullException, ArgumentException, CultureNotFoundException, ObjectDisposedException, InvalidOperationException, ArrayTypeMismatchException, PlatformNotSupportedException, ArgumentOutOfRangeException, IndexOutOfRangeException
-
FromFile
public static Image FromFile(String filename, boolean useEmbeddedColorManagement) throws Throwable, ArgumentException, ArgumentOutOfRangeException, IndexOutOfRangeException, PlatformNotSupportedException, NotSupportedException, ArgumentNullException, ObjectDisposedException, InvalidOperationException, RankException, ArrayTypeMismatchException, CultureNotFoundException, FileNotFoundException, FormatException, SerializationException
- Throws:
Throwable
ArgumentException
ArgumentOutOfRangeException
IndexOutOfRangeException
PlatformNotSupportedException
NotSupportedException
ArgumentNullException
ObjectDisposedException
InvalidOperationException
RankException
ArrayTypeMismatchException
CultureNotFoundException
FileNotFoundException
FormatException
SerializationException
-
FromFile
public static Image FromFile(String filename) throws Throwable, ArgumentException, PlatformNotSupportedException, NotSupportedException, ArgumentNullException, InvalidOperationException, ArgumentOutOfRangeException, CultureNotFoundException, FileNotFoundException, FormatException, ArrayTypeMismatchException
-
FromStream
public static Image FromStream(Stream stream, boolean useEmbeddedColorManagement, boolean validateImageData) throws Throwable, ArgumentException, ArgumentOutOfRangeException, ArgumentNullException, InvalidOperationException, PlatformNotSupportedException, ArrayTypeMismatchException, IndexOutOfRangeException, NotSupportedException, CultureNotFoundException, ObjectDisposedException, SerializationException
-
FromStream
public static Image FromStream(Stream stream, boolean useEmbeddedColorManagement) throws Throwable, ArgumentException, ArgumentOutOfRangeException, ArgumentNullException, InvalidOperationException, PlatformNotSupportedException, ArrayTypeMismatchException, IndexOutOfRangeException, NotSupportedException, ObjectDisposedException, RankException, FormatException
-
FromStream
public static Image FromStream(Stream stream) throws Throwable, ArgumentException, ArgumentOutOfRangeException, IndexOutOfRangeException, PlatformNotSupportedException, NotSupportedException, ArgumentNullException, ObjectDisposedException, InvalidOperationException, RankException, ArrayTypeMismatchException, FormatException
-
GetEncoderParameterList
public EncoderParameters GetEncoderParameterList(Guid encoder) throws Throwable, ArgumentNullException, ArgumentException, CultureNotFoundException, ObjectDisposedException, InvalidOperationException, ArrayTypeMismatchException, PlatformNotSupportedException, ArgumentOutOfRangeException, IndexOutOfRangeException, OutOfMemoryException, AccessViolationException, NotSupportedException, MethodAccessException, MissingMethodException, MemberAccessException, TargetInvocationException
- Throws:
Throwable
ArgumentNullException
ArgumentException
CultureNotFoundException
ObjectDisposedException
InvalidOperationException
ArrayTypeMismatchException
PlatformNotSupportedException
ArgumentOutOfRangeException
IndexOutOfRangeException
OutOfMemoryException
AccessViolationException
NotSupportedException
MethodAccessException
MissingMethodException
MemberAccessException
TargetInvocationException
-
GetPropertyItem
public PropertyItem GetPropertyItem(int propid) throws Throwable, ArgumentNullException, ArgumentException, CultureNotFoundException, ObjectDisposedException, InvalidOperationException, ArrayTypeMismatchException, PlatformNotSupportedException, ArgumentOutOfRangeException, IndexOutOfRangeException
-
GetBounds
public RectangleF GetBounds(JCORefOut<GraphicsUnit> pageUnit) throws Throwable, ArgumentNullException, ArgumentException, CultureNotFoundException, ObjectDisposedException, InvalidOperationException, ArrayTypeMismatchException, PlatformNotSupportedException, ArgumentOutOfRangeException, IndexOutOfRangeException
-
Clone
public NetObject Clone() throws Throwable, ArgumentNullException, ArgumentException, CultureNotFoundException, ObjectDisposedException, InvalidOperationException, ArrayTypeMismatchException, PlatformNotSupportedException, ArgumentOutOfRangeException, IndexOutOfRangeException
-
Dispose
public void Dispose() throws Throwable, ArgumentException, ArgumentOutOfRangeException, ArgumentNullException, InvalidOperationException, PlatformNotSupportedException, ArrayTypeMismatchException, IndexOutOfRangeException, NotSupportedException, ObjectDisposedException, RankException
-
RemovePropertyItem
public void RemovePropertyItem(int propid) throws Throwable, ArgumentNullException, ArgumentException, CultureNotFoundException, ObjectDisposedException, InvalidOperationException, ArrayTypeMismatchException, PlatformNotSupportedException, ArgumentOutOfRangeException, IndexOutOfRangeException
-
RotateFlip
public void RotateFlip(RotateFlipType rotateFlipType) throws Throwable, ArgumentNullException, ArgumentException, CultureNotFoundException, ObjectDisposedException, InvalidOperationException, ArrayTypeMismatchException, PlatformNotSupportedException, ArgumentOutOfRangeException, IndexOutOfRangeException
-
Save
public void Save(Stream stream, ImageCodecInfo encoder, EncoderParameters encoderParams) throws Throwable, ArgumentException, ArgumentOutOfRangeException, ArgumentNullException, InvalidOperationException, PlatformNotSupportedException, ArrayTypeMismatchException, IndexOutOfRangeException, NotSupportedException, CultureNotFoundException, ObjectDisposedException, OutOfMemoryException, AccessViolationException
- Throws:
Throwable
ArgumentException
ArgumentOutOfRangeException
ArgumentNullException
InvalidOperationException
PlatformNotSupportedException
ArrayTypeMismatchException
IndexOutOfRangeException
NotSupportedException
CultureNotFoundException
ObjectDisposedException
OutOfMemoryException
AccessViolationException
-
Save
public void Save(Stream stream, ImageFormat format) throws Throwable, ArgumentException, ArgumentOutOfRangeException, ArgumentNullException, InvalidOperationException, PlatformNotSupportedException, ArrayTypeMismatchException, IndexOutOfRangeException, NotSupportedException, CultureNotFoundException, ObjectDisposedException, OutOfMemoryException, AccessViolationException
- Throws:
Throwable
ArgumentException
ArgumentOutOfRangeException
ArgumentNullException
InvalidOperationException
PlatformNotSupportedException
ArrayTypeMismatchException
IndexOutOfRangeException
NotSupportedException
CultureNotFoundException
ObjectDisposedException
OutOfMemoryException
AccessViolationException
-
Save
public void Save(String filename, ImageCodecInfo encoder, EncoderParameters encoderParams) throws Throwable, ArgumentException, ArgumentOutOfRangeException, ArgumentNullException, InvalidOperationException, PlatformNotSupportedException, ArrayTypeMismatchException, IndexOutOfRangeException, NotSupportedException, CultureNotFoundException, ObjectDisposedException, DirectoryNotFoundException, OutOfMemoryException, AccessViolationException, SerializationException
- Throws:
Throwable
ArgumentException
ArgumentOutOfRangeException
ArgumentNullException
InvalidOperationException
PlatformNotSupportedException
ArrayTypeMismatchException
IndexOutOfRangeException
NotSupportedException
CultureNotFoundException
ObjectDisposedException
DirectoryNotFoundException
OutOfMemoryException
AccessViolationException
SerializationException
-
Save
public void Save(String filename, ImageFormat format) throws Throwable, ArgumentException, ArgumentOutOfRangeException, ArgumentNullException, InvalidOperationException, PlatformNotSupportedException, ArrayTypeMismatchException, IndexOutOfRangeException, NotSupportedException, CultureNotFoundException, ObjectDisposedException, OutOfMemoryException, DirectoryNotFoundException, AccessViolationException, SerializationException
- Throws:
Throwable
ArgumentException
ArgumentOutOfRangeException
ArgumentNullException
InvalidOperationException
PlatformNotSupportedException
ArrayTypeMismatchException
IndexOutOfRangeException
NotSupportedException
CultureNotFoundException
ObjectDisposedException
OutOfMemoryException
DirectoryNotFoundException
AccessViolationException
SerializationException
-
Save
public void Save(String filename) throws Throwable, ArgumentNullException, ArgumentException, ObjectDisposedException, InvalidOperationException, PlatformNotSupportedException, ArgumentOutOfRangeException, IndexOutOfRangeException, FormatException, OutOfMemoryException, ArrayTypeMismatchException, DirectoryNotFoundException, AccessViolationException
- Throws:
Throwable
ArgumentNullException
ArgumentException
ObjectDisposedException
InvalidOperationException
PlatformNotSupportedException
ArgumentOutOfRangeException
IndexOutOfRangeException
FormatException
OutOfMemoryException
ArrayTypeMismatchException
DirectoryNotFoundException
AccessViolationException
-
SaveAdd
public void SaveAdd(Image image, EncoderParameters encoderParams) throws Throwable, ArgumentException, ArgumentOutOfRangeException, ArgumentNullException, InvalidOperationException, PlatformNotSupportedException, ArrayTypeMismatchException, IndexOutOfRangeException, NotSupportedException, CultureNotFoundException, ObjectDisposedException, OutOfMemoryException, AccessViolationException
- Throws:
Throwable
ArgumentException
ArgumentOutOfRangeException
ArgumentNullException
InvalidOperationException
PlatformNotSupportedException
ArrayTypeMismatchException
IndexOutOfRangeException
NotSupportedException
CultureNotFoundException
ObjectDisposedException
OutOfMemoryException
AccessViolationException
-
SaveAdd
public void SaveAdd(EncoderParameters encoderParams) throws Throwable, ArgumentException, ArgumentOutOfRangeException, IndexOutOfRangeException, PlatformNotSupportedException, NotSupportedException, ArgumentNullException, ObjectDisposedException, InvalidOperationException, RankException, ArrayTypeMismatchException, OutOfMemoryException, AccessViolationException, FormatException
- Throws:
Throwable
ArgumentException
ArgumentOutOfRangeException
IndexOutOfRangeException
PlatformNotSupportedException
NotSupportedException
ArgumentNullException
ObjectDisposedException
InvalidOperationException
RankException
ArrayTypeMismatchException
OutOfMemoryException
AccessViolationException
FormatException
-
SetPropertyItem
public void SetPropertyItem(PropertyItem propitem) throws Throwable, ArgumentNullException, ArgumentException, CultureNotFoundException, ObjectDisposedException, InvalidOperationException, ArrayTypeMismatchException, PlatformNotSupportedException, ArgumentOutOfRangeException, IndexOutOfRangeException
-
GetObjectData
@Deprecated public void GetObjectData(SerializationInfo info, StreamingContext context) throws Throwable
Deprecated.Not for public use because the method is implemented in .NET with an explicit interface. Use the static ToISerializable method available in ISerializable to obtain an object with an invocable method- Specified by:
GetObjectData
in interfaceISerializable
- Throws:
Throwable
-
close
public void close() throws Exception
- Specified by:
close
in interfaceAutoCloseable
- Throws:
Exception
-
getFlags
public int getFlags() throws Throwable, ArgumentNullException, ArgumentException, CultureNotFoundException, ObjectDisposedException, InvalidOperationException, ArrayTypeMismatchException, PlatformNotSupportedException, ArgumentOutOfRangeException, IndexOutOfRangeException
-
getHeight
public int getHeight() throws Throwable, ArgumentNullException, ArgumentException, CultureNotFoundException, ObjectDisposedException, InvalidOperationException, ArrayTypeMismatchException, PlatformNotSupportedException, ArgumentOutOfRangeException, IndexOutOfRangeException
-
getWidth
public int getWidth() throws Throwable, ArgumentNullException, ArgumentException, CultureNotFoundException, ObjectDisposedException, InvalidOperationException, ArrayTypeMismatchException, PlatformNotSupportedException, ArgumentOutOfRangeException, IndexOutOfRangeException
-
getPropertyIdList
public int[] getPropertyIdList() throws Throwable, ArgumentNullException, ArgumentException, CultureNotFoundException, ObjectDisposedException, InvalidOperationException, ArrayTypeMismatchException, PlatformNotSupportedException, ArgumentOutOfRangeException, IndexOutOfRangeException
-
getHorizontalResolution
public Single getHorizontalResolution() throws Throwable, ArgumentNullException, ArgumentException, CultureNotFoundException, ObjectDisposedException, InvalidOperationException, ArrayTypeMismatchException, PlatformNotSupportedException, ArgumentOutOfRangeException, IndexOutOfRangeException
-
getVerticalResolution
public Single getVerticalResolution() throws Throwable, ArgumentNullException, ArgumentException, CultureNotFoundException, ObjectDisposedException, InvalidOperationException, ArrayTypeMismatchException, PlatformNotSupportedException, ArgumentOutOfRangeException, IndexOutOfRangeException
-
getPalette
public ColorPalette getPalette() throws Throwable, ArgumentNullException, ArgumentException, CultureNotFoundException, ObjectDisposedException, InvalidOperationException, ArrayTypeMismatchException, PlatformNotSupportedException, ArgumentOutOfRangeException, IndexOutOfRangeException, OutOfMemoryException, AccessViolationException
-
setPalette
public void setPalette(ColorPalette Palette) throws Throwable, PlatformNotSupportedException, OutOfMemoryException, AccessViolationException, InvalidOperationException, ArgumentException, ArgumentOutOfRangeException, IndexOutOfRangeException, ArgumentNullException, CultureNotFoundException, ObjectDisposedException, ArrayTypeMismatchException
-
getRawFormat
public ImageFormat getRawFormat() throws Throwable, ArgumentNullException, ArgumentException, CultureNotFoundException, ObjectDisposedException, InvalidOperationException, ArrayTypeMismatchException, PlatformNotSupportedException, ArgumentOutOfRangeException, IndexOutOfRangeException
-
getPixelFormat
public PixelFormat getPixelFormat() throws Throwable
- Throws:
Throwable
-
getPropertyItems
public final PropertyItem[] getPropertyItems() throws Throwable, ArgumentNullException, ArgumentException, CultureNotFoundException, ObjectDisposedException, InvalidOperationException, ArrayTypeMismatchException, PlatformNotSupportedException, ArgumentOutOfRangeException, IndexOutOfRangeException
-
getSize
public Size getSize() throws Throwable, ArgumentNullException, ArgumentException, ObjectDisposedException, InvalidOperationException, PlatformNotSupportedException, ArgumentOutOfRangeException, IndexOutOfRangeException, FormatException
-
getPhysicalDimension
public SizeF getPhysicalDimension() throws Throwable, ArgumentNullException, ArgumentException, CultureNotFoundException, ObjectDisposedException, InvalidOperationException, ArrayTypeMismatchException, PlatformNotSupportedException, ArgumentOutOfRangeException, IndexOutOfRangeException
-
getFrameDimensionsList
public final Guid[] getFrameDimensionsList() throws Throwable, ArgumentNullException, ArgumentException, CultureNotFoundException, ObjectDisposedException, InvalidOperationException, ArrayTypeMismatchException, PlatformNotSupportedException, ArgumentOutOfRangeException, IndexOutOfRangeException
-
-