2 Copyright (C) 2000-2005 SKYRIX Software AG
4 This file is part of SOPE.
6 SOPE is free software; you can redistribute it and/or modify it under
7 the terms of the GNU Lesser General Public License as published by the
8 Free Software Foundation; either version 2, or (at your option) any
11 SOPE is distributed in the hope that it will be useful, but WITHOUT ANY
12 WARRANTY; without even the implied warranty of MERCHANTABILITY or
13 FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
14 License for more details.
16 You should have received a copy of the GNU Lesser General Public
17 License along with SOPE; see the file COPYING. If not, write to the
18 Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA
22 #ifndef __WEExtensions_WEClientCapabilities_H__
23 #define __WEExtensions_WEClientCapabilities_H__
25 #import <Foundation/NSObject.h>
29 @interface WEClientCapabilities : NSObject
33 unsigned short browser;
36 unsigned char browserMajorVersion;
37 unsigned char browserMinorVersion;
47 - (NSString *)userAgent;
48 - (NSString *)userAgentType;
51 - (unsigned char)majorVersion;
52 - (unsigned char)minorVersion;
54 /* browser capabilities */
56 - (BOOL)isJavaScriptBrowser;
57 - (BOOL)isVBScriptBrowser;
58 - (BOOL)isFastTableBrowser;
59 - (BOOL)isCSS1Browser;
60 - (BOOL)isCSS2Browser;
61 - (BOOL)ignoresCSSOnFormElements;
62 - (BOOL)isTextModeBrowser;
63 - (BOOL)isIFrameBrowser;
67 - (BOOL)isXmlRpcClient;
71 - (BOOL)doesSupportCSSOverflow;
72 - (BOOL)doesSupportDHTMLDragAndDrop;
73 - (BOOL)doesSupportXMLDataIslands;
74 - (BOOL)doesSupportUTF8Encoding;
76 /* user-agent (it's better to use ^capabilities !) */
78 - (BOOL)isInternetExplorer;
79 - (BOOL)isInternetExplorer5;
95 - (BOOL)isWindowsBrowser;
96 - (BOOL)isLinuxBrowser;
98 - (BOOL)isSunOSBrowser;
99 - (BOOL)isUnixBrowser;
100 - (BOOL)isX11Browser;
104 #include <NGObjWeb/WORequest.h>
106 @interface WORequest(ClientCapabilities)
108 /* the object is cached in the WORequest's userInfo */
109 - (WEClientCapabilities *)clientCapabilities;
113 #include <NGObjWeb/WODynamicElement.h>
116 The following element uses JavaScript to find out even more about the client
120 @interface JSClientCapabilityDetector : WODynamicElement
122 WOAssociation *formName;
123 WOAssociation *clientCaps;
127 #endif /* __WEExtensions_WEClientCapabilities_H__ */