Package system.drawing
Class Icon
- java.lang.Object
-
- org.mases.jcobridge.netreflection.NetObject
-
- system.MarshalByRefObject
-
- system.drawing.Icon
-
- All Implemented Interfaces:
java.lang.AutoCloseable
,IJCOBridgeReflected
,ISerializable
public class Icon extends MarshalByRefObject implements ISerializable, java.lang.AutoCloseable
The base .NET class managing System.Drawing.Icon, System.Drawing.Common, Version=9.0.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51..NET documentation at https://docs.microsoft.com/en-us/dotnet/api/System.Drawing.Icon
Powered by JCOBridge: more info at https://www.jcobridge.com
- Author:
- MASES s.r.l https://masesgroup.com
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
assemblyFullName
Fully assembly qualified name: System.Drawing.Common, Version=9.0.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51static java.lang.String
assemblyShortName
Assembly name: System.Drawing.Commonstatic java.lang.String
className
Qualified class name: System.Drawing.Iconstatic JCType
classType
The type managed from JCOBridge.
-
Constructor Summary
Constructors Constructor Description Icon()
Icon(java.lang.Object instance)
Internal constructor.Icon(java.lang.String fileName)
Icon(java.lang.String fileName, int width, int height)
Icon(java.lang.String fileName, Size size)
Icon(NetType type, java.lang.String resource)
Icon(Icon original, int width, int height)
Icon(Icon original, Size size)
Icon(Stream stream)
Icon(Stream stream, int width, int height)
Icon(Stream stream, Size size)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static Icon
cast(IJCOBridgeReflected from)
Try to cast theIJCOBridgeReflected
instance intoIcon
, a cast assert is made to check if types are compatible.NetObject
Clone()
void
close()
void
Dispose()
static Icon
ExtractAssociatedIcon(java.lang.String filePath)
static Icon
ExtractIcon(java.lang.String filePath, int id, boolean smallIcon)
static Icon
ExtractIcon(java.lang.String filePath, int id, int size)
int
getHeight()
java.lang.String
getJCOAssemblyName()
Returns the reflected Assembly namejava.lang.String
getJCOClassName()
Returns the reflected Class namejava.lang.Object
getJCOInstance()
Returns the instantiated classjava.lang.String
getJCOObjectName()
Returns the reflected Class name used to build the objectJCType
getJCOType()
Returns the instantiated class TypeSize
getSize()
int
getWidth()
void
Save(Stream outputStream)
void
setJCOInstance(JCObject instance)
Bitmap
ToBitmap()
-
Methods inherited from class system.MarshalByRefObject
GetLifetimeService, InitializeLifetimeService
-
Methods inherited from class org.mases.jcobridge.netreflection.NetObject
Equals, Equals, GetHashCode, GetType, hashCode, toString, ToString
-
Methods inherited from interface system.runtime.serialization.ISerializable
GetObjectData
-
-
-
-
Field Detail
-
assemblyFullName
public static final java.lang.String assemblyFullName
Fully assembly qualified name: System.Drawing.Common, Version=9.0.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51- See Also:
- Constant Field Values
-
assemblyShortName
public static final java.lang.String assemblyShortName
Assembly name: System.Drawing.Common- See Also:
- Constant Field Values
-
className
public static final java.lang.String className
Qualified class name: System.Drawing.Icon- See Also:
- Constant Field Values
-
-
Constructor Detail
-
Icon
public Icon(java.lang.Object instance) throws java.lang.Throwable
Internal constructor. Use with caution- Throws:
java.lang.Throwable
-
Icon
public Icon() throws java.lang.Throwable
- Throws:
java.lang.Throwable
-
Icon
public Icon(Icon original, int width, int height) throws java.lang.Throwable, ArgumentException, ArgumentOutOfRangeException, PlatformNotSupportedException, NotSupportedException, ObjectDisposedException, InvalidOperationException, RankException, ArrayTypeMismatchException, ArgumentNullException, IndexOutOfRangeException, FormatException, OverflowException, Win32Exception
- Throws:
java.lang.Throwable
ArgumentException
ArgumentOutOfRangeException
PlatformNotSupportedException
NotSupportedException
ObjectDisposedException
InvalidOperationException
RankException
ArrayTypeMismatchException
ArgumentNullException
IndexOutOfRangeException
FormatException
OverflowException
Win32Exception
-
Icon
public Icon(Icon original, Size size) throws java.lang.Throwable, ArgumentException, NotSupportedException, InvalidOperationException, ArgumentOutOfRangeException, ArgumentNullException, PlatformNotSupportedException, IndexOutOfRangeException, FormatException, OverflowException, Win32Exception, ArrayTypeMismatchException
-
Icon
public Icon(Stream stream, int width, int height) throws java.lang.Throwable, ArgumentException, ArgumentOutOfRangeException, PlatformNotSupportedException, NotSupportedException, ObjectDisposedException, InvalidOperationException, RankException, ArrayTypeMismatchException, ArgumentNullException, IOException, IndexOutOfRangeException, FormatException, OverflowException, Win32Exception
- Throws:
java.lang.Throwable
ArgumentException
ArgumentOutOfRangeException
PlatformNotSupportedException
NotSupportedException
ObjectDisposedException
InvalidOperationException
RankException
ArrayTypeMismatchException
ArgumentNullException
IOException
IndexOutOfRangeException
FormatException
OverflowException
Win32Exception
-
Icon
public Icon(Stream stream, Size size) throws java.lang.Throwable, ArgumentException, NotSupportedException, InvalidOperationException, ArgumentOutOfRangeException, ArgumentNullException, ArrayTypeMismatchException, PlatformNotSupportedException, IOException, IndexOutOfRangeException, FormatException, OverflowException, Win32Exception
-
Icon
public Icon(Stream stream) throws java.lang.Throwable, ArgumentException, NotSupportedException, InvalidOperationException, ArgumentOutOfRangeException, ArgumentNullException, ArrayTypeMismatchException, PlatformNotSupportedException, IOException, IndexOutOfRangeException, FormatException, OverflowException, Win32Exception
-
Icon
public Icon(java.lang.String fileName, int width, int height) throws java.lang.Throwable, ArgumentNullException, ArgumentException, ArgumentOutOfRangeException, PlatformNotSupportedException, OutOfMemoryException, SerializationException, CultureNotFoundException, NotSupportedException, InvalidOperationException, ObjectDisposedException, OverflowException, FormatException, Win32Exception, ArrayTypeMismatchException
- Throws:
java.lang.Throwable
ArgumentNullException
ArgumentException
ArgumentOutOfRangeException
PlatformNotSupportedException
OutOfMemoryException
SerializationException
CultureNotFoundException
NotSupportedException
InvalidOperationException
ObjectDisposedException
OverflowException
FormatException
Win32Exception
ArrayTypeMismatchException
-
Icon
public Icon(java.lang.String fileName, Size size) throws java.lang.Throwable, ArgumentException, ArgumentOutOfRangeException, PlatformNotSupportedException, SerializationException, CultureNotFoundException, ObjectDisposedException, InvalidOperationException, IndexOutOfRangeException, OverflowException, FormatException, Win32Exception
-
Icon
public Icon(java.lang.String fileName) throws java.lang.Throwable, ArgumentException, ArgumentOutOfRangeException, PlatformNotSupportedException, SerializationException, CultureNotFoundException, ObjectDisposedException, InvalidOperationException, IndexOutOfRangeException, OverflowException, FormatException, Win32Exception
-
Icon
public Icon(NetType type, java.lang.String resource) throws java.lang.Throwable, ArgumentException, ArgumentOutOfRangeException, PlatformNotSupportedException, NotSupportedException, ObjectDisposedException, InvalidOperationException, RankException, ArrayTypeMismatchException, ArgumentNullException, IndexOutOfRangeException, FormatException, OverflowException, Win32Exception
- Throws:
java.lang.Throwable
ArgumentException
ArgumentOutOfRangeException
PlatformNotSupportedException
NotSupportedException
ObjectDisposedException
InvalidOperationException
RankException
ArrayTypeMismatchException
ArgumentNullException
IndexOutOfRangeException
FormatException
OverflowException
Win32Exception
-
-
Method Detail
-
getJCOAssemblyName
public java.lang.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 java.lang.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 java.lang.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 java.lang.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 Icon cast(IJCOBridgeReflected from) throws java.lang.Throwable
Try to cast theIJCOBridgeReflected
instance intoIcon
, a cast assert is made to check if types are compatible.- Parameters:
from
-IJCOBridgeReflected
instance to be casted- Returns:
Icon
instance- Throws:
java.lang.Throwable
- in case of error during cast operation
-
ToBitmap
public Bitmap ToBitmap() throws java.lang.Throwable, ArgumentException, NotSupportedException, InvalidOperationException, ArgumentOutOfRangeException, ArgumentNullException, PlatformNotSupportedException, ObjectDisposedException, FormatException, ArrayTypeMismatchException, OverflowException, OutOfMemoryException
-
ExtractAssociatedIcon
public static Icon ExtractAssociatedIcon(java.lang.String filePath) throws java.lang.Throwable, ArgumentException, NotSupportedException, InvalidOperationException, ArgumentOutOfRangeException, ArgumentNullException, IndexOutOfRangeException, PlatformNotSupportedException, CultureNotFoundException, MissingMethodException, TargetInvocationException, FileNotFoundException, FormatException
- Throws:
java.lang.Throwable
ArgumentException
NotSupportedException
InvalidOperationException
ArgumentOutOfRangeException
ArgumentNullException
IndexOutOfRangeException
PlatformNotSupportedException
CultureNotFoundException
MissingMethodException
TargetInvocationException
FileNotFoundException
FormatException
-
ExtractIcon
public static Icon ExtractIcon(java.lang.String filePath, int id, boolean smallIcon) throws java.lang.Throwable, ArgumentException, NotSupportedException, InvalidOperationException, ArgumentOutOfRangeException, ArgumentNullException, IOException, PlatformNotSupportedException, IndexOutOfRangeException, FormatException
-
ExtractIcon
public static Icon ExtractIcon(java.lang.String filePath, int id, int size) throws java.lang.Throwable, ArgumentException, NotSupportedException, InvalidOperationException, ArgumentOutOfRangeException, ArgumentNullException, IOException, PlatformNotSupportedException, IndexOutOfRangeException, FormatException
-
Clone
public NetObject Clone() throws java.lang.Throwable, ArgumentException, NotSupportedException, InvalidOperationException, ArgumentOutOfRangeException, ArgumentNullException, PlatformNotSupportedException, IndexOutOfRangeException, FormatException, OverflowException, Win32Exception, ArrayTypeMismatchException
-
Dispose
public void Dispose() throws java.lang.Throwable, ArgumentException, NotSupportedException, InvalidOperationException, ArgumentOutOfRangeException, ArgumentNullException
- Throws:
java.lang.Throwable
ArgumentException
NotSupportedException
InvalidOperationException
ArgumentOutOfRangeException
ArgumentNullException
-
Save
public void Save(Stream outputStream) throws java.lang.Throwable, ArgumentException, ArgumentOutOfRangeException, PlatformNotSupportedException, NotSupportedException, ObjectDisposedException, InvalidOperationException, RankException, ArrayTypeMismatchException, ArgumentNullException
-
close
public void close() throws java.lang.Exception
- Specified by:
close
in interfacejava.lang.AutoCloseable
- Throws:
java.lang.Exception
-
getHeight
public int getHeight() throws java.lang.Throwable
- Throws:
java.lang.Throwable
-
getWidth
public int getWidth() throws java.lang.Throwable
- Throws:
java.lang.Throwable
-
getSize
public Size getSize() throws java.lang.Throwable
- Throws:
java.lang.Throwable
-
-