1 11 package org.eclipse.swt.internal.ole.win32; 12 13 public class IStorage extends IUnknown 14 { 15 public IStorage(int address) { 16 super(address); 17 } 18 public int Commit(int grfCommitFlag) { 19 return COM.VtblCall(9, address, grfCommitFlag); 20 } 21 public int CopyTo( 22 int ciidExclude, GUID rgiidExclude, String [] snbExclude, int pstgDest ){ 27 if (snbExclude != null) { 29 return COM.E_INVALIDARG; 30 } 31 return COM.VtblCall(7, address, ciidExclude, rgiidExclude, 0, pstgDest); 32 } 33 public int CreateStorage( 34 String pwcsName, int grfMode, int reserved1, int reserved2, int [] ppStg ){ 40 41 char[] buffer = null; 43 if (pwcsName != null) { 44 buffer = (pwcsName+"\0").toCharArray(); 45 } 46 47 return COM.VtblCall(5, address, buffer, grfMode, reserved1, reserved2, ppStg); 48 } 49 public int CreateStream( 50 String pwcsName, int grfMode, int reserved1, int reserved2, int [] ppStm ){ 56 57 char[] buffer = null; 59 if (pwcsName != null) { 60 buffer = (pwcsName+"\0").toCharArray(); 61 } 62 63 return COM.VtblCall(3, address, buffer, grfMode, reserved1, reserved2, ppStm); 64 } 65 public int DestroyElement(String pwcsName) { 66 67 char[] buffer = null; 69 if (pwcsName != null) { 70 buffer = (pwcsName+"\0").toCharArray(); 71 } 72 return COM.VtblCall(12, address, buffer); 73 } 74 public int EnumElements( 75 int reserved1, int reserved2, int reserved3, int [] ppenum ){ 81 return COM.VtblCall(11, address, reserved1, reserved2, reserved3, ppenum); 82 } 83 public int OpenStorage( 84 String pwcsName, int pstgPriority, int grfMode, String snbExclude[], int reserved, int [] ppStg ){ 92 93 char[] buffer = null; 95 if (pwcsName != null) { 96 buffer = (pwcsName+"\0").toCharArray(); 97 } 98 99 if (snbExclude != null) { 101 return COM.E_INVALIDARG; 102 } 103 return COM.VtblCall(6, address, buffer, pstgPriority, grfMode, 0, reserved, ppStg); 104 } 105 public int OpenStream( 106 String pwcsName, int reserved1, int grfMode, int reserved2, int [] ppStm ) { 113 114 char[] buffer = null; 116 if (pwcsName != null) { 117 buffer = (pwcsName+"\0").toCharArray(); 118 } 119 120 return COM.VtblCall(4, address, buffer, reserved1, grfMode, reserved2, ppStm); 121 } 122 public int RenameElement( 123 String pwcsOldName, String pwcsNewName ){ 128 129 char[] buffer1 = null; 131 if (pwcsOldName != null) { 132 buffer1 = (pwcsOldName+"\0").toCharArray(); 133 } 134 char[] buffer2 = null; 136 if (pwcsNewName != null) { 137 buffer2 = (pwcsNewName+"\0").toCharArray(); 138 } 139 return COM.VtblCall(13, address, buffer1, buffer2); 140 } 141 public int Revert() { 142 return COM.VtblCall(10, address); 143 } 144 public int SetClass( 145 GUID clsid ){ 147 return COM.VtblCall(15, address, clsid); 148 } 149 } 150 | Popular Tags |