|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.jniwrapper.win32.stg.StorageFunctions
This class provides functions for working with Structured Storage objects.
Constructor Summary | |
StorageFunctions()
|
Method Summary | |
static ILockBytes |
createILockBytesOnHGlobal(GlobalMemoryBlock global,
boolean deleteOnRelease)
Creates a byte array object that allows you to use global memory as the physical device underneath a compound file implementation. |
static IStream |
createStreamOnHGlobal(GlobalMemoryBlock global,
boolean deleteOnRelease)
Creates a stream object stored in global memory. |
static GlobalMemoryBlock |
getGlobalFromILockBytes(ILockBytes lockBytes)
Retrieves a global memory handle to a byte array object created using the CreateILockBytesOnHGlobal function. |
static CLSID |
readClassStg(IStorage pStg)
|
static CLSID |
readClassStm(IStream pStg)
|
static IStorage |
stgCreateDocfile(BStr pwcsName,
StgMode grfMode,
Int32 reserved)
|
static IStorage |
stgCreateDocfileOnILockBytes(ILockBytes plkbyt,
StgMode grfMode,
Int32 reserved)
|
static IStorage |
stgCreateStorageEx(BStr pwcsName,
StgMode grfMode,
StgFmt stgfmt,
UInt32 grfAttrs,
StgOptions stgOptions,
Pointer.Void reserved2,
IID iid)
|
static boolean |
stgIsStorageFile(java.lang.String lpwcsFileName)
|
static Int32 |
stgIsStorageILockBytes(ILockBytes plkbyt)
|
static IStorage |
stgOpenStorage(java.lang.String pwcsName,
IStorage pstgPriority,
StgMode grfMode,
BStr snbExclude)
|
static IStorage |
stgOpenStorageEx(BStr pwcsName,
StgMode grfMode,
StgFmt stgfmt,
UInt32 grfAttrs,
StgOptions stgOptions,
Pointer.Void reserved2,
IID iid)
|
static IStorage |
stgOpenStorageOnILockBytes(ILockBytes plkbyt,
IStorage pstgPriority,
StgMode grfMode,
BStr snbExclude,
Int32 reserved)
|
static void |
writeClassStg(IStorage pStg,
CLSID rclsid)
|
static void |
writeClassStm(IStream pStg,
CLSID rclsid)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public StorageFunctions()
Method Detail |
public static boolean stgIsStorageFile(java.lang.String lpwcsFileName) throws ComException, java.io.IOException
lpwcsFileName
- [in]
ComException
java.io.IOException
public static IStorage stgOpenStorage(java.lang.String pwcsName, IStorage pstgPriority, StgMode grfMode, BStr snbExclude) throws ComException
pwcsName
- [in]
pstgPriority
- [in]
grfMode
- [in]
snbExclude
- [in]
ComException
public static IStorage stgCreateStorageEx(BStr pwcsName, StgMode grfMode, StgFmt stgfmt, UInt32 grfAttrs, StgOptions stgOptions, Pointer.Void reserved2, IID iid) throws ComException
pwcsName
- [in]
grfMode
- [in]
stgfmt
- [in]
grfAttrs
- [in]
stgOptions
- [in]
reserved2
- [in]
iid
- [in]
ComException
public static IStorage stgOpenStorageEx(BStr pwcsName, StgMode grfMode, StgFmt stgfmt, UInt32 grfAttrs, StgOptions stgOptions, Pointer.Void reserved2, IID iid) throws ComException
pwcsName
- [in]
grfMode
- [in]
stgfmt
- [in]
grfAttrs
- [in]
stgOptions
- [in]
reserved2
- [in]
iid
- [in]
ComException
public static IStorage stgCreateDocfile(BStr pwcsName, StgMode grfMode, Int32 reserved) throws ComException
pwcsName
- [in]
grfMode
- [in]
reserved
- [in]
Note. You should call IStorage.release() manually after working with created object
ComException
public static GlobalMemoryBlock getGlobalFromILockBytes(ILockBytes lockBytes) throws ComException
CreateILockBytesOnHGlobal
function.
lockBytes
- the ILockBytes interface on the byte-array object previously created by a call to the CreateILockBytesOnHGlobal
function.
ComException
public static ILockBytes createILockBytesOnHGlobal(GlobalMemoryBlock global, boolean deleteOnRelease) throws ComException
global
- Memory handle.deleteOnRelease
- Determines whether the underlying handle for this byte array object should be automatically freed when the object is released.
ComException
public static IStream createStreamOnHGlobal(GlobalMemoryBlock global, boolean deleteOnRelease) throws ComException
global
- Memory handle allocated by the GlobalAlloc
function.deleteOnRelease
- Whether the underlying handle for this stream object should be automatically freed when the stream object is released.
ComException
public static IStorage stgCreateDocfileOnILockBytes(ILockBytes plkbyt, StgMode grfMode, Int32 reserved) throws ComException
plkbyt
- [in]
grfMode
- [in]
reserved
- [in]
ComException
public static IStorage stgOpenStorageOnILockBytes(ILockBytes plkbyt, IStorage pstgPriority, StgMode grfMode, BStr snbExclude, Int32 reserved) throws ComException
plkbyt
- [in]
pstgPriority
- [in]
grfMode
- [in]
snbExclude
- [in]
reserved
- [in]
ComException
public static Int32 stgIsStorageILockBytes(ILockBytes plkbyt)
plkbyt
- [in]
public static CLSID readClassStg(IStorage pStg) throws ComException
pStg
- [in]
ComException
public static void writeClassStg(IStorage pStg, CLSID rclsid) throws ComException
pStg
- [in]
rclsid
- [in]
ComException
public static CLSID readClassStm(IStream pStg) throws ComException
pStg
- [in]
ComException
public static void writeClassStm(IStream pStg, CLSID rclsid) throws ComException
pStg
- [in]
rclsid
- [in]
ComException
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |