1 module org.eclipse.swt.internal.mozilla.nsICookie; 2 3 import java.lang.all; 4 5 import org.eclipse.swt.internal.mozilla.Common; 6 import org.eclipse.swt.internal.mozilla.nsID; 7 import org.eclipse.swt.internal.mozilla.nsISupports; 8 import org.eclipse.swt.internal.mozilla.nsStringAPI; 9 10 alias PRInt32 nsCookieStatus; 11 alias PRInt32 nsCookiePolicy; 12 13 const char[] NS_ICOOKIE_IID_STR = "e9fcb9a4-d376-458f-b720-e65e7df593bc"; 14 15 const nsIID NS_ICOOKIE_IID= 16 {0xe9fcb9a4, 0xd376, 0x458f, 17 [ 0xb7, 0x20, 0xe6, 0x5e, 0x7d, 0xf5, 0x93, 0xbc ]}; 18 19 interface nsICookie : nsISupports { 20 21 static const char[] IID_STR = NS_ICOOKIE_IID_STR; 22 static const nsIID IID = NS_ICOOKIE_IID; 23 24 extern(System): 25 nsresult GetName(nsACString * aName); 26 nsresult GetValue(nsACString * aValue); 27 nsresult GetIsDomain(PRBool *aIsDomain); 28 nsresult GetHost(nsACString * aHost); 29 nsresult GetPath(nsACString * aPath); 30 nsresult GetIsSecure(PRBool *aIsSecure); 31 nsresult GetExpires(PRUint64 *aExpires); 32 33 enum { STATUS_UNKNOWN = 0 }; 34 enum { STATUS_ACCEPTED = 1 }; 35 enum { STATUS_DOWNGRADED = 2 }; 36 enum { STATUS_FLAGGED = 3 }; 37 enum { STATUS_REJECTED = 4 }; 38 39 nsresult GetStatus(nsCookieStatus *aStatus); 40 41 enum { POLICY_UNKNOWN = 0 }; 42 enum { POLICY_NONE = 1 }; 43 enum { POLICY_NO_CONSENT = 2 }; 44 enum { POLICY_IMPLICIT_CONSENT = 3 }; 45 enum { POLICY_EXPLICIT_CONSENT = 4 }; 46 enum { POLICY_NO_II = 5 }; 47 48 nsresult GetPolicy(nsCookiePolicy *aPolicy); 49 } 50