Changeset 147403 in webkit


Ignore:
Timestamp:
Apr 2, 2013 1:32:49 AM (11 years ago)
Author:
mikhail.pozdnyakov@intel.com
Message:

[WK2] Remove repeating code in declaration of WK2 API classes
https://bugs.webkit.org/show_bug.cgi?id=112782

Reviewed by Benjamin Poulain.

The following two lines of code had been repeated in every WK2 API
object class:
1) static const Type APIType = SomeAPIType;
2) virtual Type type() const { return APIType; }

This patch introduces template class 'TypedAPIObject' inherited
from WebKit::APIObject and it contains the common functionality.
So the new pattern is that API object classes are inherited from
TypedAPIObject (rather than from WebKit::APIObject directly) passing
the corresponding API object type as a template parameter.

The existing API object classes are modified accordingly to the
proposed pattern.

  • Shared/APIObject.h:

(WebKit):
(TypedAPIObject):
(WebKit::TypedAPIObject::~TypedAPIObject):
(WebKit::TypedAPIObject::TypedAPIObject):

  • Shared/ImmutableArray.h:

(ImmutableArray):

  • Shared/ImmutableDictionary.h:

(ImmutableDictionary):

  • Shared/WebArchive.h:

(WebArchive):

  • Shared/WebArchiveResource.h:

(WebArchiveResource):

  • Shared/WebBackForwardListItem.h:

(WebBackForwardListItem):

  • Shared/WebBatteryStatus.h:

(WebBatteryStatus):

  • Shared/WebCertificateInfo.h:
  • Shared/WebConnection.h:

(WebConnection):

  • Shared/WebContextMenuItem.h:

(WebContextMenuItem):

  • Shared/WebData.h:
  • Shared/WebError.h:

(WebKit::WebError::errorCode):

  • Shared/WebGeolocationPosition.h:

(WebGeolocationPosition):

  • Shared/WebGeometry.h:
  • Shared/WebGraphicsContext.h:

(WebGraphicsContext):

  • Shared/WebHitTestResult.h:
  • Shared/WebImage.h:

(WebImage):

  • Shared/WebNetworkInfo.h:

(WebNetworkInfo):

  • Shared/WebNumber.h:
  • Shared/WebOpenPanelParameters.h:

(WebOpenPanelParameters):

  • Shared/WebRenderLayer.h:
  • Shared/WebRenderObject.h:
  • Shared/WebSecurityOrigin.h:
  • Shared/WebSerializedScriptValue.h:

(WebSerializedScriptValue):

  • Shared/WebString.h:
  • Shared/WebURL.h:
  • Shared/WebURLRequest.h:

(WebURLRequest):

  • Shared/WebURLResponse.h:

(WebURLResponse):

  • Shared/WebUserContentURLPattern.h:
  • Shared/mac/ObjCObjectGraph.h:
  • UIProcess/Authentication/AuthenticationChallengeProxy.h:

(AuthenticationChallengeProxy):

  • UIProcess/Authentication/AuthenticationDecisionListener.h:

(AuthenticationDecisionListener):

  • UIProcess/Authentication/WebCredential.h:

(WebCredential):

  • UIProcess/Authentication/WebProtectionSpace.h:

(WebProtectionSpace):

  • UIProcess/Downloads/DownloadProxy.h:

(DownloadProxy):

  • UIProcess/GeolocationPermissionRequestProxy.h:

(GeolocationPermissionRequestProxy):

  • UIProcess/Notifications/NotificationPermissionRequest.h:

(NotificationPermissionRequest):

  • UIProcess/Notifications/WebNotification.h:

(WebNotification):

  • UIProcess/Notifications/WebNotificationManagerProxy.h:

(WebNotificationManagerProxy):

  • UIProcess/Plugins/WebPluginSiteDataManager.h:

(WebPluginSiteDataManager):

  • UIProcess/WebApplicationCacheManagerProxy.h:

(WebApplicationCacheManagerProxy):

  • UIProcess/WebBackForwardList.h:

(WebBackForwardList):

  • UIProcess/WebBatteryManagerProxy.h:

(WebBatteryManagerProxy):

  • UIProcess/WebContext.h:

(WebContext):

  • UIProcess/WebCookieManagerProxy.h:

(WebCookieManagerProxy):

  • UIProcess/WebDatabaseManagerProxy.h:

(WebDatabaseManagerProxy):

  • UIProcess/WebEditCommandProxy.h:

(WebEditCommandProxy):

  • UIProcess/WebFrameProxy.h:

(WebFrameProxy):

  • UIProcess/WebGeolocationManagerProxy.h:

(WebGeolocationManagerProxy):

  • UIProcess/WebGrammarDetail.h:

(WebGrammarDetail):

  • UIProcess/WebIconDatabase.h:

(WebIconDatabase):

  • UIProcess/WebInspectorProxy.h:

(WebInspectorProxy):

  • UIProcess/WebKeyValueStorageManagerProxy.h:

(WebKeyValueStorageManagerProxy):

  • UIProcess/WebMediaCacheManagerProxy.h:

(WebMediaCacheManagerProxy):

  • UIProcess/WebNavigationData.h:

(WebNavigationData):

  • UIProcess/WebNetworkInfoManagerProxy.h:

(WebNetworkInfoManagerProxy):

  • UIProcess/WebOpenPanelResultListenerProxy.h:

(WebOpenPanelResultListenerProxy):

  • UIProcess/WebPageGroup.h:

(WebPageGroup):

  • UIProcess/WebPageProxy.h:

(WebPageProxy):

  • UIProcess/WebPreferences.cpp:

(WebKit::WebPreferences::WebPreferences):

  • UIProcess/WebPreferences.h:

(WebPreferences):

  • UIProcess/WebResourceCacheManagerProxy.h:

(WebResourceCacheManagerProxy):

  • UIProcess/WebTextChecker.h:

(WebTextChecker):

  • UIProcess/WebVibrationProxy.h:

(WebVibrationProxy):

  • UIProcess/efl/WebPopupItemEfl.h:

(WebPopupItemEfl):

  • UIProcess/efl/WebView.h:
  • UIProcess/soup/WebSoupRequestManagerProxy.h:

(WebSoupRequestManagerProxy):

  • WebProcess/InjectedBundle/DOM/InjectedBundleNodeHandle.h:

(InjectedBundleNodeHandle):

  • WebProcess/InjectedBundle/DOM/InjectedBundleRangeHandle.h:

(InjectedBundleRangeHandle):

  • WebProcess/InjectedBundle/InjectedBundle.h:

(InjectedBundle):

  • WebProcess/InjectedBundle/InjectedBundleBackForwardList.h:
  • WebProcess/InjectedBundle/InjectedBundleBackForwardListItem.h:
  • WebProcess/InjectedBundle/InjectedBundleDOMWindowExtension.h:

(InjectedBundleDOMWindowExtension):

  • WebProcess/InjectedBundle/InjectedBundleHitTestResult.h:
  • WebProcess/InjectedBundle/InjectedBundleNavigationAction.h:

(InjectedBundleNavigationAction):

  • WebProcess/InjectedBundle/InjectedBundleScriptWorld.h:

(InjectedBundleScriptWorld):

  • WebProcess/WebPage/PageOverlay.h:

(PageOverlay):

  • WebProcess/WebPage/WebFrame.h:

(WebFrame):

  • WebProcess/WebPage/WebInspector.h:

(WebInspector):

  • WebProcess/WebPage/WebPage.h:

(WebPage):

  • WebProcess/WebPage/WebPageGroupProxy.h:

(WebPageGroupProxy):

Location:
trunk/Source/WebKit2
Files:
82 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebKit2/ChangeLog

    r147362 r147403  
     12013-04-02  Mikhail Pozdnyakov  <mikhail.pozdnyakov@intel.com>
     2
     3        [WK2] Remove repeating code in declaration of WK2 API classes
     4        https://bugs.webkit.org/show_bug.cgi?id=112782
     5
     6        Reviewed by Benjamin Poulain.
     7
     8        The following two lines of code had been repeated in every WK2 API
     9        object class:
     10        1) static const Type APIType = SomeAPIType;
     11        2) virtual Type type() const { return APIType; }
     12
     13        This patch introduces template class 'TypedAPIObject' inherited
     14        from WebKit::APIObject and it contains the common functionality.
     15        So the new pattern is that API object classes are inherited from
     16        TypedAPIObject (rather than from WebKit::APIObject directly) passing
     17        the corresponding API object type as a template parameter.
     18
     19        The existing API object classes are modified accordingly to the
     20        proposed pattern.
     21
     22        * Shared/APIObject.h:
     23        (WebKit):
     24        (TypedAPIObject):
     25        (WebKit::TypedAPIObject::~TypedAPIObject):
     26        (WebKit::TypedAPIObject::TypedAPIObject):
     27        * Shared/ImmutableArray.h:
     28        (ImmutableArray):
     29        * Shared/ImmutableDictionary.h:
     30        (ImmutableDictionary):
     31        * Shared/WebArchive.h:
     32        (WebArchive):
     33        * Shared/WebArchiveResource.h:
     34        (WebArchiveResource):
     35        * Shared/WebBackForwardListItem.h:
     36        (WebBackForwardListItem):
     37        * Shared/WebBatteryStatus.h:
     38        (WebBatteryStatus):
     39        * Shared/WebCertificateInfo.h:
     40        * Shared/WebConnection.h:
     41        (WebConnection):
     42        * Shared/WebContextMenuItem.h:
     43        (WebContextMenuItem):
     44        * Shared/WebData.h:
     45        * Shared/WebError.h:
     46        (WebKit::WebError::errorCode):
     47        * Shared/WebGeolocationPosition.h:
     48        (WebGeolocationPosition):
     49        * Shared/WebGeometry.h:
     50        * Shared/WebGraphicsContext.h:
     51        (WebGraphicsContext):
     52        * Shared/WebHitTestResult.h:
     53        * Shared/WebImage.h:
     54        (WebImage):
     55        * Shared/WebNetworkInfo.h:
     56        (WebNetworkInfo):
     57        * Shared/WebNumber.h:
     58        * Shared/WebOpenPanelParameters.h:
     59        (WebOpenPanelParameters):
     60        * Shared/WebRenderLayer.h:
     61        * Shared/WebRenderObject.h:
     62        * Shared/WebSecurityOrigin.h:
     63        * Shared/WebSerializedScriptValue.h:
     64        (WebSerializedScriptValue):
     65        * Shared/WebString.h:
     66        * Shared/WebURL.h:
     67        * Shared/WebURLRequest.h:
     68        (WebURLRequest):
     69        * Shared/WebURLResponse.h:
     70        (WebURLResponse):
     71        * Shared/WebUserContentURLPattern.h:
     72        * Shared/mac/ObjCObjectGraph.h:
     73        * UIProcess/Authentication/AuthenticationChallengeProxy.h:
     74        (AuthenticationChallengeProxy):
     75        * UIProcess/Authentication/AuthenticationDecisionListener.h:
     76        (AuthenticationDecisionListener):
     77        * UIProcess/Authentication/WebCredential.h:
     78        (WebCredential):
     79        * UIProcess/Authentication/WebProtectionSpace.h:
     80        (WebProtectionSpace):
     81        * UIProcess/Downloads/DownloadProxy.h:
     82        (DownloadProxy):
     83        * UIProcess/GeolocationPermissionRequestProxy.h:
     84        (GeolocationPermissionRequestProxy):
     85        * UIProcess/Notifications/NotificationPermissionRequest.h:
     86        (NotificationPermissionRequest):
     87        * UIProcess/Notifications/WebNotification.h:
     88        (WebNotification):
     89        * UIProcess/Notifications/WebNotificationManagerProxy.h:
     90        (WebNotificationManagerProxy):
     91        * UIProcess/Plugins/WebPluginSiteDataManager.h:
     92        (WebPluginSiteDataManager):
     93        * UIProcess/WebApplicationCacheManagerProxy.h:
     94        (WebApplicationCacheManagerProxy):
     95        * UIProcess/WebBackForwardList.h:
     96        (WebBackForwardList):
     97        * UIProcess/WebBatteryManagerProxy.h:
     98        (WebBatteryManagerProxy):
     99        * UIProcess/WebContext.h:
     100        (WebContext):
     101        * UIProcess/WebCookieManagerProxy.h:
     102        (WebCookieManagerProxy):
     103        * UIProcess/WebDatabaseManagerProxy.h:
     104        (WebDatabaseManagerProxy):
     105        * UIProcess/WebEditCommandProxy.h:
     106        (WebEditCommandProxy):
     107        * UIProcess/WebFrameProxy.h:
     108        (WebFrameProxy):
     109        * UIProcess/WebGeolocationManagerProxy.h:
     110        (WebGeolocationManagerProxy):
     111        * UIProcess/WebGrammarDetail.h:
     112        (WebGrammarDetail):
     113        * UIProcess/WebIconDatabase.h:
     114        (WebIconDatabase):
     115        * UIProcess/WebInspectorProxy.h:
     116        (WebInspectorProxy):
     117        * UIProcess/WebKeyValueStorageManagerProxy.h:
     118        (WebKeyValueStorageManagerProxy):
     119        * UIProcess/WebMediaCacheManagerProxy.h:
     120        (WebMediaCacheManagerProxy):
     121        * UIProcess/WebNavigationData.h:
     122        (WebNavigationData):
     123        * UIProcess/WebNetworkInfoManagerProxy.h:
     124        (WebNetworkInfoManagerProxy):
     125        * UIProcess/WebOpenPanelResultListenerProxy.h:
     126        (WebOpenPanelResultListenerProxy):
     127        * UIProcess/WebPageGroup.h:
     128        (WebPageGroup):
     129        * UIProcess/WebPageProxy.h:
     130        (WebPageProxy):
     131        * UIProcess/WebPreferences.cpp:
     132        (WebKit::WebPreferences::WebPreferences):
     133        * UIProcess/WebPreferences.h:
     134        (WebPreferences):
     135        * UIProcess/WebResourceCacheManagerProxy.h:
     136        (WebResourceCacheManagerProxy):
     137        * UIProcess/WebTextChecker.h:
     138        (WebTextChecker):
     139        * UIProcess/WebVibrationProxy.h:
     140        (WebVibrationProxy):
     141        * UIProcess/efl/WebPopupItemEfl.h:
     142        (WebPopupItemEfl):
     143        * UIProcess/efl/WebView.h:
     144        * UIProcess/soup/WebSoupRequestManagerProxy.h:
     145        (WebSoupRequestManagerProxy):
     146        * WebProcess/InjectedBundle/DOM/InjectedBundleNodeHandle.h:
     147        (InjectedBundleNodeHandle):
     148        * WebProcess/InjectedBundle/DOM/InjectedBundleRangeHandle.h:
     149        (InjectedBundleRangeHandle):
     150        * WebProcess/InjectedBundle/InjectedBundle.h:
     151        (InjectedBundle):
     152        * WebProcess/InjectedBundle/InjectedBundleBackForwardList.h:
     153        * WebProcess/InjectedBundle/InjectedBundleBackForwardListItem.h:
     154        * WebProcess/InjectedBundle/InjectedBundleDOMWindowExtension.h:
     155        (InjectedBundleDOMWindowExtension):
     156        * WebProcess/InjectedBundle/InjectedBundleHitTestResult.h:
     157        * WebProcess/InjectedBundle/InjectedBundleNavigationAction.h:
     158        (InjectedBundleNavigationAction):
     159        * WebProcess/InjectedBundle/InjectedBundleScriptWorld.h:
     160        (InjectedBundleScriptWorld):
     161        * WebProcess/WebPage/PageOverlay.h:
     162        (PageOverlay):
     163        * WebProcess/WebPage/WebFrame.h:
     164        (WebFrame):
     165        * WebProcess/WebPage/WebInspector.h:
     166        (WebInspector):
     167        * WebProcess/WebPage/WebPage.h:
     168        (WebPage):
     169        * WebProcess/WebPage/WebPageGroupProxy.h:
     170        (WebPageGroupProxy):
     171
    11722013-04-01  Timothy Hatcher  <timothy@apple.com>
    2173
  • trunk/Source/WebKit2/Shared/APIObject.h

    r143275 r147403  
    149149};
    150150
     151template <APIObject::Type ArgumentType>
     152class TypedAPIObject : public APIObject {
     153public:
     154    static const Type APIType = ArgumentType;
     155
     156    virtual ~TypedAPIObject()
     157    {
     158    }
     159
     160protected:
     161    TypedAPIObject()
     162    {
     163    }
     164
     165    virtual Type type() const OVERRIDE { return APIType; }
     166};
     167
    151168} // namespace WebKit
    152169
  • trunk/Source/WebKit2/Shared/ImmutableArray.h

    r130948 r147403  
    3636// ImmutableArray - An immutable array type suitable for vending to an API.
    3737
    38 class ImmutableArray : public APIObject {
     38class ImmutableArray : public TypedAPIObject<APIObject::TypeArray> {
    3939public:
    40     static const Type APIType = TypeArray;
    4140    enum AdoptTag { Adopt };
    4241
     
    7473    ImmutableArray(Vector<RefPtr<APIObject> >& entries);
    7574
    76     virtual Type type() const { return APIType; }
    77 
    7875    Vector<RefPtr<APIObject> > m_entries;
    7976};
  • trunk/Source/WebKit2/Shared/ImmutableDictionary.h

    r95901 r147403  
    3939// ImmutableDictionary - An immutable dictionary type suitable for vending to an API.
    4040
    41 class ImmutableDictionary : public APIObject {
     41class ImmutableDictionary : public TypedAPIObject<APIObject::TypeDictionary> {
    4242public:
    43     static const Type APIType = TypeDictionary;
    44 
    4543    typedef HashMap<String, RefPtr<APIObject> > MapType;
    4644
     
    8684    ImmutableDictionary(MapType& map);
    8785
    88     virtual Type type() const { return APIType; }
    89 
    9086    MapType m_map;
    9187};
  • trunk/Source/WebKit2/Shared/WebArchive.h

    r141473 r147403  
    4444class WebData;
    4545
    46 class WebArchive : public APIObject {
     46class WebArchive : public TypedAPIObject<APIObject::TypeWebArchive> {
    4747public:
    48     static const Type APIType = TypeWebArchive;
    4948    virtual ~WebArchive();
    5049
     
    6766    WebArchive(PassRefPtr<WebCore::LegacyWebArchive>);
    6867
    69     virtual Type type() const { return APIType; }
    70 
    7168    RefPtr<WebCore::LegacyWebArchive> m_legacyWebArchive;
    7269    RefPtr<WebArchiveResource> m_cachedMainResource;
  • trunk/Source/WebKit2/Shared/WebArchiveResource.h

    r141473 r147403  
    4444class WebURL;
    4545
    46 class WebArchiveResource : public APIObject {
     46class WebArchiveResource : public TypedAPIObject<APIObject::TypeWebArchiveResource> {
    4747public:
    48     static const Type APIType = TypeWebArchiveResource;
    4948    virtual ~WebArchiveResource();
    5049
     
    6362    WebArchiveResource(PassRefPtr<WebCore::ArchiveResource>);
    6463
    65     virtual Type type() const { return APIType; }
    66 
    6764    RefPtr<WebCore::ArchiveResource> m_archiveResource;
    6865};
  • trunk/Source/WebKit2/Shared/WebBackForwardListItem.h

    r95901 r147403  
    3838namespace WebKit {
    3939
    40 class WebBackForwardListItem : public APIObject {
     40class WebBackForwardListItem : public TypedAPIObject<APIObject::TypeBackForwardListItem> {
    4141public:
    42     static const Type APIType = TypeBackForwardListItem;
    43 
    4442    static PassRefPtr<WebBackForwardListItem> create(const String& originalURL, const String& url, const String& title, const uint8_t* backForwardData, size_t backForwardDataSize, uint64_t itemID)
    4543    {
     
    7169    WebBackForwardListItem(const String& originalURL, const String& url, const String& title, const uint8_t* backForwardData, size_t backForwardDataSize, uint64_t itemID);
    7270
    73     virtual Type type() const { return APIType; }
    74 
    7571    String m_originalURL;
    7672    String m_url;
  • trunk/Source/WebKit2/Shared/WebBatteryStatus.h

    r141639 r147403  
    3636namespace WebKit {
    3737
    38 class WebBatteryStatus : public APIObject {
     38class WebBatteryStatus : public TypedAPIObject<APIObject::TypeBatteryStatus> {
    3939public:
    40     static const Type APIType = TypeBatteryStatus;
    41 
    4240    struct Data {
    4341        void encode(CoreIPC::ArgumentEncoder&) const;
     
    6664    WebBatteryStatus(bool isCharging, double chargingTime, double dischargingTime, double level);
    6765
    68     virtual Type type() const { return APIType; }
    69 
    7066    Data m_data;
    7167};
  • trunk/Source/WebKit2/Shared/WebCertificateInfo.h

    r95901 r147403  
    3333namespace WebKit {
    3434
    35 class WebCertificateInfo : public APIObject {
     35class WebCertificateInfo : public TypedAPIObject<APIObject::TypeCertificateInfo> {
    3636public:
    37     static const Type APIType = TypeCertificateInfo;
    38 
    3937    static PassRefPtr<WebCertificateInfo> create(const PlatformCertificateInfo& info)
    4038    {
     
    5048    }
    5149
    52     virtual Type type() const { return APIType; }
    53 
    5450    PlatformCertificateInfo m_platformCertificateInfo;
    5551};
  • trunk/Source/WebKit2/Shared/WebConnection.h

    r141361 r147403  
    3535namespace WebKit {
    3636
    37 class WebConnection : public APIObject, public CoreIPC::MessageReceiver, public CoreIPC::MessageSender<WebConnection> {
     37class WebConnection : public TypedAPIObject<APIObject::TypeConnection>, public CoreIPC::MessageReceiver, public CoreIPC::MessageSender<WebConnection> {
    3838public:
    39     static const Type APIType = TypeConnection;
    4039    virtual ~WebConnection();
    4140
     
    5049protected:
    5150    explicit WebConnection();
    52 
    53     virtual Type type() const { return APIType; }
    5451
    5552    virtual void encodeMessageBody(CoreIPC::ArgumentEncoder&, APIObject*) = 0;
  • trunk/Source/WebKit2/Shared/WebContextMenuItem.h

    r114367 r147403  
    3636class ImmutableArray;
    3737
    38 class WebContextMenuItem : public APIObject {
     38class WebContextMenuItem : public TypedAPIObject<APIObject::TypeContextMenuItem> {
    3939public:
    40     static const Type APIType = TypeContextMenuItem;
    41 
    4240    static PassRefPtr<WebContextMenuItem> create(const WebContextMenuItemData& data)
    4341    {
     
    5654private:
    5755    WebContextMenuItem(const WebContextMenuItemData&);
    58    
    59     virtual Type type() const { return APIType; }
    60    
     56
    6157    WebContextMenuItemData m_webContextMenuItemData;
    6258};
  • trunk/Source/WebKit2/Shared/WebData.h

    r95901 r147403  
    3636// WebData - A data buffer type suitable for vending to an API.
    3737
    38 class WebData : public APIObject {
     38class WebData : public TypedAPIObject<APIObject::TypeData> {
    3939public:
    40     static const Type APIType = TypeData;
    41 
    4240    typedef void (*FreeDataFunction)(unsigned char*, const void* context);
    4341
     
    8987    }
    9088
    91     virtual Type type() const { return APIType; }
    92 
    9389    const unsigned char* m_bytes;
    9490    size_t m_size;
  • trunk/Source/WebKit2/Shared/WebError.h

    r95901 r147403  
    3535// WebError - An error type suitable for vending to an API.
    3636
    37 class WebError : public APIObject {
     37class WebError : public TypedAPIObject<APIObject::TypeError> {
    3838public:
    39     static const Type APIType = TypeError;
    40 
    4139    static PassRefPtr<WebError> create()
    4240    {
     
    5250
    5351    const String& domain() const { return m_platformError.domain(); }
    54     int errorCode() const { return m_platformError.errorCode();; }
     52    int errorCode() const { return m_platformError.errorCode(); }
    5553    const String& failingURL() const { return m_platformError.failingURL(); }
    5654    const String& localizedDescription() const { return m_platformError.localizedDescription(); }
     
    6866    }
    6967
    70     virtual Type type() const { return APIType; }
    71 
    7268    WebCore::ResourceError m_platformError;
    7369};
  • trunk/Source/WebKit2/Shared/WebGeolocationPosition.h

    r141619 r147403  
    3434namespace WebKit {
    3535
    36 class WebGeolocationPosition : public APIObject {
     36class WebGeolocationPosition : public TypedAPIObject<APIObject::TypeGeolocationPosition> {
    3737public:
    38     static const Type APIType = TypeGeolocationPosition;
    39 
    4038    struct Data {
    4139        void encode(CoreIPC::ArgumentEncoder&) const;
     
    8785    WebGeolocationPosition(double timestamp, double latitude, double longitude, double accuracy, bool providesAltitude, double altitude, bool providesAltitudeAccuracy, double altitudeAccuracy, bool providesHeading, double heading, bool providesSpeed, double speed);
    8886
    89     virtual Type type() const { return APIType; }
    90 
    9187    Data m_data;
    9288};
  • trunk/Source/WebKit2/Shared/WebGeometry.h

    r95759 r147403  
    3939namespace WebKit {
    4040
    41 class WebSize : public APIObject {
     41class WebSize : public TypedAPIObject<APIObject::TypeSize> {
    4242public:
    43     static const Type APIType = TypeSize;
    44 
    4543    static PassRefPtr<WebSize> create(const WKSize& size)
    4644    {
     
    5553    { }
    5654
    57     virtual Type type() const { return APIType; }
    58 
    5955    WKSize m_size;
    6056};
    6157
    62 class WebPoint : public APIObject {
     58class WebPoint : public TypedAPIObject<APIObject::TypePoint> {
    6359public:
    64     static const Type APIType = TypePoint;
    65 
    6660    static PassRefPtr<WebPoint> create(const WKPoint& point)
    6761    {
     
    7670    { }
    7771
    78     virtual Type type() const { return APIType; }
    79 
    8072    WKPoint m_point;
    8173};
    8274
    83 class WebRect : public APIObject {
     75class WebRect : public TypedAPIObject<APIObject::TypeRect> {
    8476public:
    85     static const Type APIType = TypeRect;
    86 
    8777    static PassRefPtr<WebRect> create(const WKRect& rect)
    8878    {
     
    9787    { }
    9888
    99     virtual Type type() const { return APIType; }
    100 
    10189    WKRect m_rect;
    10290};
  • trunk/Source/WebKit2/Shared/WebGraphicsContext.h

    r104958 r147403  
    3939namespace WebKit {
    4040
    41 class WebGraphicsContext : public APIObject {
     41class WebGraphicsContext : public TypedAPIObject<APIObject::TypeGraphicsContext> {
    4242public:
    43     static const Type APIType = TypeGraphicsContext;
    44 
    4543    static PassRefPtr<WebGraphicsContext> create(WebCore::GraphicsContext* graphicsContext)
    4644    {
     
    5856    explicit WebGraphicsContext(WebCore::GraphicsContext*);
    5957
    60     virtual Type type() const { return APIType; }
    61 
    6258#if USE(CG)
    6359    RetainPtr<CGContextRef> m_platformContext;
  • trunk/Source/WebKit2/Shared/WebHitTestResult.h

    r141619 r147403  
    4040class WebFrame;
    4141
    42 class WebHitTestResult : public APIObject {
     42class WebHitTestResult : public TypedAPIObject<APIObject::TypeHitTestResult> {
    4343public:
    44     static const Type APIType = TypeHitTestResult;
    45 
    4644    struct Data {
    4745        String absoluteImageURL;
     
    115113    }
    116114
    117     virtual Type type() const { return APIType; }
    118 
    119115    Data m_data;
    120116};
  • trunk/Source/WebKit2/Shared/WebImage.h

    r95901 r147403  
    4141// WebImage - An image type suitable for vending to an API.
    4242
    43 class WebImage : public APIObject {
     43class WebImage : public TypedAPIObject<APIObject::TypeImage> {
    4444public:
    45     static const Type APIType = TypeImage;
    46 
    4745    static PassRefPtr<WebImage> create(const WebCore::IntSize&, ImageOptions);
    4846    static PassRefPtr<WebImage> create(PassRefPtr<ShareableBitmap>);
     
    5654    WebImage(PassRefPtr<ShareableBitmap>);
    5755
    58     virtual Type type() const { return APIType; }
    59 
    6056    RefPtr<ShareableBitmap> m_bitmap;
    6157};
  • trunk/Source/WebKit2/Shared/WebNetworkInfo.h

    r141639 r147403  
    3636namespace WebKit {
    3737
    38 class WebNetworkInfo : public APIObject {
     38class WebNetworkInfo : public TypedAPIObject<APIObject::TypeNetworkInfo> {
    3939public:
    40     static const Type APIType = TypeNetworkInfo;
    41 
    4240    struct Data {
    4341        void encode(CoreIPC::ArgumentEncoder&) const;
     
    6361    WebNetworkInfo(double bandwidth, bool metered);
    6462
    65     virtual Type type() const { return APIType; }
    66 
    6763    Data m_data;
    6864};
  • trunk/Source/WebKit2/Shared/WebNumber.h

    r95901 r147403  
    3333
    3434template<typename NumberType, APIObject::Type APIObjectType>
    35 class WebNumber : public APIObject {
     35class WebNumber : public TypedAPIObject<APIObjectType> {
    3636public:
    37     static const Type APIType = APIObjectType;
    38 
    3937    static PassRefPtr<WebNumber> create(NumberType value)
    4038    {
     
    5048    }
    5149
    52     virtual Type type() const { return APIType; }
    53 
    5450    const NumberType m_value;
    5551};
  • trunk/Source/WebKit2/Shared/WebOpenPanelParameters.h

    r125512 r147403  
    3737class ImmutableArray;
    3838
    39 class WebOpenPanelParameters : public APIObject {
     39class WebOpenPanelParameters : public TypedAPIObject<APIObject::TypeOpenPanelParameters> {
    4040public:
    41     static const Type APIType = TypeOpenPanelParameters;
    42 
    4341    static PassRefPtr<WebOpenPanelParameters> create(const WebCore::FileChooserSettings&);
    4442    ~WebOpenPanelParameters();
     
    5452    explicit WebOpenPanelParameters(const WebCore::FileChooserSettings&);
    5553
    56     virtual Type type() const { return APIType; }
    57 
    5854    WebCore::FileChooserSettings m_settings;
    5955};
  • trunk/Source/WebKit2/Shared/WebRenderLayer.h

    r121584 r147403  
    3737class WebPage;
    3838
    39 class WebRenderLayer : public APIObject {
     39class WebRenderLayer : public TypedAPIObject<APIObject::TypeRenderLayer> {
    4040public:
    41     static const Type APIType = TypeRenderLayer;
    42 
    4341    enum CompositingLayerType { None, Normal, Tiled, Media, Container };
    4442
     
    7775    }
    7876
    79     virtual Type type() const OVERRIDE { return APIType; }
    80 
    8177    static PassRefPtr<MutableArray> createArrayFromLayerList(Vector<WebCore::RenderLayer*>*);
    8278
  • trunk/Source/WebKit2/Shared/WebRenderObject.h

    r121584 r147403  
    4141class WebPage;
    4242
    43 class WebRenderObject : public APIObject {
     43class WebRenderObject : public TypedAPIObject<APIObject::TypeRenderObject> {
    4444public:
    45     static const Type APIType = TypeRenderObject;
    46 
    4745    static PassRefPtr<WebRenderObject> create(WebPage*);
    4846    static PassRefPtr<WebRenderObject> create(WebCore::RenderObject* renderer)
     
    8078    }
    8179
    82     virtual Type type() const OVERRIDE { return APIType; }
    83 
    8480    RefPtr<MutableArray> m_children;
    8581
  • trunk/Source/WebKit2/Shared/WebSecurityOrigin.h

    r133425 r147403  
    3333namespace WebKit {
    3434
    35 class WebSecurityOrigin : public APIObject {
     35class WebSecurityOrigin : public TypedAPIObject<APIObject::TypeSecurityOrigin> {
    3636public:
    37     static const Type APIType = TypeSecurityOrigin;
    38 
    3937    static PassRefPtr<WebSecurityOrigin> createFromString(const String& string)
    4038    {
     
    7270    }
    7371
    74     virtual Type type() const { return APIType; }
    75 
    7672    RefPtr<WebCore::SecurityOrigin> m_securityOrigin;
    7773};
  • trunk/Source/WebKit2/Shared/WebSerializedScriptValue.h

    r140902 r147403  
    3535namespace WebKit {
    3636
    37 class WebSerializedScriptValue : public APIObject {
     37class WebSerializedScriptValue : public TypedAPIObject<APIObject::TypeSerializedScriptValue> {
    3838public:
    39     static const Type APIType = TypeSerializedScriptValue;
    40    
    4139    static PassRefPtr<WebSerializedScriptValue> create(PassRefPtr<WebCore::SerializedScriptValue> serializedValue)
    4240    {
     
    7169    {
    7270    }
    73    
    74     virtual Type type() const { return APIType; }
    75    
     71
    7672    RefPtr<WebCore::SerializedScriptValue> m_serializedScriptValue;
    7773};
  • trunk/Source/WebKit2/Shared/WebString.h

    r131777 r147403  
    3939// WebString - A string type suitable for vending to an API.
    4040
    41 class WebString : public APIObject {
     41class WebString : public TypedAPIObject<APIObject::TypeString> {
    4242public:
    43     static const Type APIType = TypeString;
    44 
    4543    static PassRefPtr<WebString> createNull()
    4644    {
     
    113111    }
    114112
    115     virtual Type type() const { return APIType; }
    116 
    117113    String m_string;
    118114};
  • trunk/Source/WebKit2/Shared/WebURL.h

    r131437 r147403  
    3838// WebURL - A URL type suitable for vending to an API.
    3939
    40 class WebURL : public APIObject {
     40class WebURL : public TypedAPIObject<APIObject::TypeURL> {
    4141public:
    42     static const Type APIType = TypeURL;
    43 
    4442    static PassRefPtr<WebURL> create(const String& string)
    4543    {
     
    106104    }
    107105
    108     virtual Type type() const { return APIType; }
    109 
    110106    String m_string;
    111107    mutable OwnPtr<WebCore::KURL> m_parsedURL;
  • trunk/Source/WebKit2/Shared/WebURLRequest.h

    r139023 r147403  
    3939namespace WebKit {
    4040
    41 class WebURLRequest : public APIObject {
     41class WebURLRequest : public TypedAPIObject<APIObject::TypeURLRequest> {
    4242public:
    43     static const Type APIType = TypeURLRequest;
    44 
    4543    static PassRefPtr<WebURLRequest> create(const WebCore::KURL&);
    4644
     
    6765    explicit WebURLRequest(PlatformRequest);
    6866
    69     virtual Type type() const { return APIType; }
    70 
    7167    WebCore::ResourceRequest m_request;
    7268};
  • trunk/Source/WebKit2/Shared/WebURLResponse.h

    r139023 r147403  
    3939namespace WebKit {
    4040
    41 class WebURLResponse : public APIObject {
     41class WebURLResponse : public TypedAPIObject<APIObject::TypeURLResponse> {
    4242public:
    43     static const Type APIType = TypeURLResponse;
    44 
    4543    static PassRefPtr<WebURLResponse> create(const WebCore::ResourceResponse& response)
    4644    {
     
    6058    explicit WebURLResponse(PlatformResponse);
    6159
    62     virtual Type type() const { return APIType; }
    63 
    6460    WebCore::ResourceResponse m_response;
    6561};
  • trunk/Source/WebKit2/Shared/WebUserContentURLPattern.h

    r98894 r147403  
    3535namespace WebKit {
    3636
    37 class WebUserContentURLPattern : public APIObject {
     37class WebUserContentURLPattern : public TypedAPIObject<APIObject::TypeUserContentURLPattern> {
    3838public:
    39     static const Type APIType = TypeUserContentURLPattern;
    40 
    4139    static PassRefPtr<WebUserContentURLPattern> create(const String& pattern)
    4240    {
     
    5957    }
    6058
    61     virtual Type type() const { return APIType; }
    62 
    6359    WebCore::UserContentURLPattern m_pattern;
    6460    String m_patternString;
  • trunk/Source/WebKit2/Shared/mac/ObjCObjectGraph.h

    r136095 r147403  
    3232namespace WebKit {
    3333
    34 class ObjCObjectGraph : public APIObject {
     34class ObjCObjectGraph : public TypedAPIObject<APIObject::TypeObjCObjectGraph> {
    3535public:
    36     static const Type APIType = TypeObjCObjectGraph;
    37 
    3836    static PassRefPtr<ObjCObjectGraph> create(id rootObject)
    3937    {
     
    4947    }
    5048
    51     virtual Type type() const { return APIType; }
    52 
    5349    RetainPtr<id> m_rootObject;
    5450};
  • trunk/Source/WebKit2/UIProcess/Authentication/AuthenticationChallengeProxy.h

    r141150 r147403  
    4242class WebProtectionSpace;
    4343
    44 class AuthenticationChallengeProxy : public APIObject {
     44class AuthenticationChallengeProxy : public TypedAPIObject<APIObject::TypeAuthenticationChallenge> {
    4545public:
    46     static const Type APIType = TypeAuthenticationChallenge;
    47 
    4846    static PassRefPtr<AuthenticationChallengeProxy> create(const WebCore::AuthenticationChallenge& authenticationChallenge, uint64_t challengeID, CoreIPC::Connection* connection)
    4947    {
     
    6563    AuthenticationChallengeProxy(const WebCore::AuthenticationChallenge&, uint64_t challengeID, CoreIPC::Connection*);
    6664
    67     virtual Type type() const { return APIType; }
    68    
    6965    WebCore::AuthenticationChallenge m_coreAuthenticationChallenge;
    7066    uint64_t m_challengeID;
  • trunk/Source/WebKit2/UIProcess/Authentication/AuthenticationDecisionListener.h

    r128683 r147403  
    3636class WebCredential;
    3737
    38 class AuthenticationDecisionListener : public APIObject {
     38class AuthenticationDecisionListener : public TypedAPIObject<APIObject::TypeAuthenticationDecisionListener> {
    3939public:
    40     static const Type APIType = TypeAuthenticationDecisionListener;
    41 
    4240    static PassRefPtr<AuthenticationDecisionListener> create(AuthenticationChallengeProxy* authenticationChallenge)
    4341    {
     
    5351    explicit AuthenticationDecisionListener(AuthenticationChallengeProxy*);
    5452
    55     virtual Type type() const { return APIType; }
    56    
    5753    AuthenticationChallengeProxy* m_challengeProxy;
    5854};
  • trunk/Source/WebKit2/UIProcess/Authentication/WebCredential.h

    r142908 r147403  
    3838class WebCertificateInfo;
    3939
    40 class WebCredential : public APIObject {
     40class WebCredential : public TypedAPIObject<APIObject::TypeCredential> {
    4141public:
    4242    ~WebCredential();
    43 
    44     static const Type APIType = TypeCredential;
    4543
    4644    static PassRefPtr<WebCredential> create(const WebCore::Credential& credential)
     
    6967    explicit WebCredential(WebCertificateInfo*);
    7068
    71     virtual Type type() const { return APIType; }
    72 
    7369    WebCore::Credential m_coreCredential;
    7470    RefPtr<WebCertificateInfo> m_certificateInfo;
  • trunk/Source/WebKit2/UIProcess/Authentication/WebProtectionSpace.h

    r128683 r147403  
    3333namespace WebKit {
    3434
    35 class WebProtectionSpace : public APIObject {
     35class WebProtectionSpace : public TypedAPIObject<APIObject::TypeProtectionSpace> {
    3636public:
    37     static const Type APIType = TypeProtectionSpace;
    38 
    3937    static PassRefPtr<WebProtectionSpace> create(const WebCore::ProtectionSpace& protectionSpace)
    4038    {
     
    5452    explicit WebProtectionSpace(const WebCore::ProtectionSpace&);
    5553
    56     virtual Type type() const { return APIType; }
    57    
    5854    WebCore::ProtectionSpace m_coreProtectionSpace;
    5955};
  • trunk/Source/WebKit2/UIProcess/Downloads/DownloadProxy.h

    r141361 r147403  
    4747class WebPageProxy;
    4848
    49 class DownloadProxy : public APIObject, public CoreIPC::MessageReceiver {
     49class DownloadProxy : public TypedAPIObject<APIObject::TypeDownload>, public CoreIPC::MessageReceiver {
    5050public:
    51     static const Type APIType = TypeDownload;
    52 
    5351    static PassRefPtr<DownloadProxy> create(DownloadProxyMap&, WebContext*);
    5452    ~DownloadProxy();
     
    7270private:
    7371    explicit DownloadProxy(DownloadProxyMap&, WebContext*);
    74 
    75     virtual Type type() const { return APIType; }
    7672
    7773    // CoreIPC::MessageReceiver
  • trunk/Source/WebKit2/UIProcess/GeolocationPermissionRequestProxy.h

    r95901 r147403  
    3434class GeolocationPermissionRequestManagerProxy;
    3535
    36 class GeolocationPermissionRequestProxy : public APIObject {
     36class GeolocationPermissionRequestProxy : public TypedAPIObject<APIObject::TypeGeolocationPermissionRequest> {
    3737public:
    38     static const Type APIType = TypeGeolocationPermissionRequest;
    39 
    4038    static PassRefPtr<GeolocationPermissionRequestProxy> create(GeolocationPermissionRequestManagerProxy* manager, uint64_t geolocationID)
    4139    {
     
    5149    GeolocationPermissionRequestProxy(GeolocationPermissionRequestManagerProxy*, uint64_t geolocationID);
    5250
    53     virtual Type type() const { return APIType; }
    54 
    5551    GeolocationPermissionRequestManagerProxy* m_manager;
    5652    uint64_t m_geolocationID;
  • trunk/Source/WebKit2/UIProcess/Notifications/NotificationPermissionRequest.h

    r102352 r147403  
    3434class NotificationPermissionRequestManagerProxy;
    3535
    36 class NotificationPermissionRequest : public APIObject {
     36class NotificationPermissionRequest : public TypedAPIObject<APIObject::TypeNotificationPermissionRequest> {
    3737public:
    38     static const Type APIType = TypeNotificationPermissionRequest;
    39    
    4038    static PassRefPtr<NotificationPermissionRequest> create(NotificationPermissionRequestManagerProxy*, uint64_t notificationID);
    41    
     39
    4240    void allow();
    4341    void deny();
    44    
     42
    4543    void invalidate();
    46    
     44
    4745private:
    4846    NotificationPermissionRequest(NotificationPermissionRequestManagerProxy*, uint64_t notificationID);
    49    
    50     virtual Type type() const { return APIType; }
    51    
     47
    5248    NotificationPermissionRequestManagerProxy* m_manager;
    5349    uint64_t m_notificationID;   
  • trunk/Source/WebKit2/UIProcess/Notifications/WebNotification.h

    r128113 r147403  
    4242namespace WebKit {
    4343
    44 class WebNotification : public APIObject {
     44class WebNotification : public TypedAPIObject<APIObject::TypeNotification> {
    4545public:
    46     static const Type APIType = TypeNotification;
    47    
    4846    static PassRefPtr<WebNotification> create(const String& title, const String& body, const String& iconURL, const String& tag, const String& lang, const String& dir, const String& originString, uint64_t notificationID)
    4947    {
    5048        return adoptRef(new WebNotification(title, body, iconURL, tag, lang, dir, originString, notificationID));
    5149    }
    52    
     50
    5351    const String& title() const { return m_title; }
    5452    const String& body() const { return m_body; }
     
    6462    WebNotification(const String& title, const String& body, const String& iconURL, const String& tag, const String& lang, const String& dir, const String& originString, uint64_t notificationID);
    6563
    66     virtual Type type() const { return APIType; }
    67    
    6864    String m_title;
    6965    String m_body;
  • trunk/Source/WebKit2/UIProcess/Notifications/WebNotificationManagerProxy.h

    r141658 r147403  
    4444class WebSecurityOrigin;
    4545
    46 class WebNotificationManagerProxy : public APIObject, public WebContextSupplement, private CoreIPC::MessageReceiver {
     46class WebNotificationManagerProxy : public TypedAPIObject<APIObject::TypeNotificationManager>, public WebContextSupplement, private CoreIPC::MessageReceiver {
    4747public:
    48     static const Type APIType = TypeNotificationManager;
    4948
    5049    static const char* supplementName();
     
    6867private:
    6968    explicit WebNotificationManagerProxy(WebContext*);
    70    
    71     virtual Type type() const { return APIType; }
    7269
    7370    // WebContextSupplement
  • trunk/Source/WebKit2/UIProcess/Plugins/WebPluginSiteDataManager.h

    r145328 r147403  
    4242typedef GenericCallback<WKArrayRef> ArrayCallback;
    4343
    44 class WebPluginSiteDataManager : public APIObject {
     44class WebPluginSiteDataManager : public TypedAPIObject<APIObject::TypePluginSiteDataManager> {
    4545public:
    46     static const Type APIType = TypePluginSiteDataManager;
    47 
    4846    static PassRefPtr<WebPluginSiteDataManager> create(WebContext*);
    4947    virtual ~WebPluginSiteDataManager();
     
    6866    explicit WebPluginSiteDataManager(WebContext*);
    6967
    70     virtual Type type() const { return APIType; }
    71 
    7268    WebContext* m_webContext;
    7369    HashMap<uint64_t, RefPtr<ArrayCallback> > m_arrayCallbacks;
  • trunk/Source/WebKit2/UIProcess/WebApplicationCacheManagerProxy.h

    r141711 r147403  
    4747typedef GenericCallback<WKArrayRef> ArrayCallback;
    4848
    49 class WebApplicationCacheManagerProxy : public APIObject, public WebContextSupplement, private CoreIPC::MessageReceiver {
     49class WebApplicationCacheManagerProxy : public TypedAPIObject<APIObject::TypeApplicationCacheManager>, public WebContextSupplement, private CoreIPC::MessageReceiver {
    5050public:
    51     static const Type APIType = TypeApplicationCacheManager;
    52 
    5351    static const char* supplementName();
    5452
     
    6563private:
    6664    explicit WebApplicationCacheManagerProxy(WebContext*);
    67 
    68     virtual Type type() const { return APIType; }
    6965
    7066    void didGetApplicationCacheOrigins(const Vector<SecurityOriginData>&, uint64_t callbackID);
  • trunk/Source/WebKit2/UIProcess/WebBackForwardList.h

    r128683 r147403  
    4848 */
    4949
    50 class WebBackForwardList : public APIObject {
     50class WebBackForwardList : public TypedAPIObject<APIObject::TypeBackForwardList> {
    5151public:
    52     static const Type APIType = TypeBackForwardList;
    53 
    5452    static PassRefPtr<WebBackForwardList> create(WebPageProxy* page)
    5553    {
     
    8886    explicit WebBackForwardList(WebPageProxy*);
    8987
    90     virtual Type type() const { return APIType; }
    91 
    9288    WebPageProxy* m_page;
    9389    BackForwardListItemVector m_entries;
  • trunk/Source/WebKit2/UIProcess/WebBatteryManagerProxy.h

    r141366 r147403  
    3838class WebContext;
    3939class WebBatteryStatus;
    40 class WebBatteryManagerProxy : public APIObject, private CoreIPC::MessageReceiver {
     40class WebBatteryManagerProxy : public TypedAPIObject<APIObject::TypeBatteryManager>, private CoreIPC::MessageReceiver {
    4141
    4242public:
    43     static const Type APIType = TypeBatteryManager;
    44 
    4543    static PassRefPtr<WebBatteryManagerProxy> create(WebContext*);
    4644    virtual ~WebBatteryManagerProxy();
     
    5654private:
    5755    explicit WebBatteryManagerProxy(WebContext*);
    58 
    59     virtual Type type() const { return APIType; }
    6056
    6157    // CoreIPC::MessageReceiver
  • trunk/Source/WebKit2/UIProcess/WebContext.h

    r146823 r147403  
    8686#endif
    8787
    88 class WebContext : public APIObject, private CoreIPC::MessageReceiver
     88class WebContext : public TypedAPIObject<APIObject::TypeContext>, private CoreIPC::MessageReceiver
    8989#if ENABLE(NETSCAPE_PLUGIN_API)
    9090    , private PluginInfoStoreClient
     
    9292    {
    9393public:
    94     static const Type APIType = TypeContext;
    95 
    9694    static PassRefPtr<WebContext> create(const String& injectedBundlePath);
    9795    virtual ~WebContext();
     
    304302    WebContext(ProcessModel, const String& injectedBundlePath);
    305303    void platformInitialize();
    306 
    307     virtual Type type() const { return APIType; }
    308304
    309305    void platformInitializeWebProcess(WebProcessCreationParameters&);
  • trunk/Source/WebKit2/UIProcess/WebCookieManagerProxy.h

    r141711 r147403  
    4949typedef GenericCallback<WKHTTPCookieAcceptPolicy, HTTPCookieAcceptPolicy> HTTPCookieAcceptPolicyCallback;
    5050
    51 class WebCookieManagerProxy : public APIObject, public WebContextSupplement, private CoreIPC::MessageReceiver {
     51class WebCookieManagerProxy : public TypedAPIObject<APIObject::TypeCookieManager>, public WebContextSupplement, private CoreIPC::MessageReceiver {
    5252public:
    53     static const Type APIType = TypeCookieManager;
    54 
    5553    static const char* supplementName();
    5654
     
    8078private:
    8179    WebCookieManagerProxy(WebContext*);
    82 
    83     virtual Type type() const { return APIType; }
    8480
    8581    void didGetHostnamesWithCookies(const Vector<String>&, uint64_t callbackID);
  • trunk/Source/WebKit2/UIProcess/WebDatabaseManagerProxy.h

    r141711 r147403  
    4747typedef GenericCallback<WKArrayRef> ArrayCallback;
    4848
    49 class WebDatabaseManagerProxy : public APIObject, public WebContextSupplement, private CoreIPC::MessageReceiver {
     49class WebDatabaseManagerProxy : public TypedAPIObject<APIObject::TypeDatabaseManager>, public WebContextSupplement, private CoreIPC::MessageReceiver {
    5050public:
    51     static const Type APIType = TypeDatabaseManager;
    52 
    5351    static const char* supplementName();
    5452
     
    8078    explicit WebDatabaseManagerProxy(WebContext*);
    8179
    82     virtual Type type() const { return APIType; }
    83 
    8480    // WebContextSupplement
    8581    virtual void contextDestroyed() OVERRIDE;
  • trunk/Source/WebKit2/UIProcess/WebEditCommandProxy.h

    r95901 r147403  
    3737class WebPageProxy;
    3838
    39 class WebEditCommandProxy : public APIObject {
     39class WebEditCommandProxy : public TypedAPIObject<APIObject::TypeEditCommandProxy> {
    4040public:
    4141    static PassRefPtr<WebEditCommandProxy> create(uint64_t commandID, WebCore::EditAction editAction, WebPageProxy* page)
     
    5858    WebEditCommandProxy(uint64_t commandID, WebCore::EditAction, WebPageProxy*);
    5959
    60     virtual Type type() const { return TypeEditCommandProxy; }
    61 
    6260    uint64_t m_commandID;
    6361    WebCore::EditAction m_editAction;
  • trunk/Source/WebKit2/UIProcess/WebFrameProxy.h

    r141708 r147403  
    5252typedef GenericCallback<WKDataRef> DataCallback;
    5353
    54 class WebFrameProxy : public APIObject {
     54class WebFrameProxy : public TypedAPIObject<APIObject::TypeFrame> {
    5555public:
    56     static const Type APIType = TypeFrame;
    57 
    5856    static PassRefPtr<WebFrameProxy> create(WebPageProxy* page, uint64_t frameID)
    5957    {
     
    123121    WebFrameProxy(WebPageProxy* page, uint64_t frameID);
    124122
    125     virtual Type type() const { return APIType; }
    126 
    127123    WebPageProxy* m_page;
    128124    LoadState m_loadState;
  • trunk/Source/WebKit2/UIProcess/WebGeolocationManagerProxy.h

    r141658 r147403  
    3838class WebGeolocationPosition;
    3939
    40 class WebGeolocationManagerProxy : public APIObject, public WebContextSupplement, private CoreIPC::MessageReceiver {
     40class WebGeolocationManagerProxy : public TypedAPIObject<APIObject::TypeGeolocationManager>, public WebContextSupplement, private CoreIPC::MessageReceiver {
    4141public:
    42     static const Type APIType = TypeGeolocationManager;
    43 
    4442    static const char* supplementName();
    4543
     
    5755private:
    5856    explicit WebGeolocationManagerProxy(WebContext*);
    59 
    60     virtual Type type() const { return APIType; }
    6157
    6258    // WebContextSupplement
  • trunk/Source/WebKit2/UIProcess/WebGrammarDetail.h

    r128683 r147403  
    3636class ImmutableArray;
    3737
    38 class WebGrammarDetail : public APIObject {
     38class WebGrammarDetail : public TypedAPIObject<APIObject::TypeGrammarDetail> {
    3939public:
    40     static const Type APIType = TypeGrammarDetail;
    4140    static PassRefPtr<WebGrammarDetail> create(int location, int length, ImmutableArray* guesses, const String& userDescription);
    4241    static PassRefPtr<WebGrammarDetail> create(const WebCore::GrammarDetail&);
     
    5352    explicit WebGrammarDetail(const WebCore::GrammarDetail&);
    5453
    55     virtual Type type() const { return APIType; }
    56 
    5754    WebCore::GrammarDetail m_grammarDetail;
    5855};
  • trunk/Source/WebKit2/UIProcess/WebIconDatabase.h

    r141472 r147403  
    5454class WebContext;
    5555
    56 class WebIconDatabase : public APIObject, public WebCore::IconDatabaseClient, private CoreIPC::MessageReceiver {
     56class WebIconDatabase : public TypedAPIObject<APIObject::TypeIconDatabase>, public WebCore::IconDatabaseClient, private CoreIPC::MessageReceiver {
    5757public:
    58     static const Type APIType = TypeIconDatabase;
    59 
    6058    static PassRefPtr<WebIconDatabase> create(WebContext*);
    6159    virtual ~WebIconDatabase();
     
    9391    WebIconDatabase(WebContext*);
    9492
    95     virtual Type type() const { return APIType; }
    96 
    9793    // WebCore::IconDatabaseClient
    9894    virtual void didImportIconURLForPageURL(const String&);
  • trunk/Source/WebKit2/UIProcess/WebInspectorProxy.h

    r147004 r147403  
    6868};
    6969
    70 class WebInspectorProxy : public APIObject, public CoreIPC::MessageReceiver {
     70class WebInspectorProxy : public TypedAPIObject<APIObject::TypeInspector>, public CoreIPC::MessageReceiver {
    7171public:
    72     static const Type APIType = TypeInspector;
    73 
    7472    static PassRefPtr<WebInspectorProxy> create(WebPageProxy* page)
    7573    {
     
    147145private:
    148146    explicit WebInspectorProxy(WebPageProxy*);
    149 
    150     virtual Type type() const { return APIType; }
    151147
    152148    // CoreIPC::MessageReceiver
  • trunk/Source/WebKit2/UIProcess/WebKeyValueStorageManagerProxy.h

    r141658 r147403  
    4545typedef GenericCallback<WKArrayRef> ArrayCallback;
    4646
    47 class WebKeyValueStorageManagerProxy : public APIObject, public WebContextSupplement, private CoreIPC::MessageReceiver {
     47class WebKeyValueStorageManagerProxy : public TypedAPIObject<APIObject::TypeKeyValueStorageManager>, public WebContextSupplement, private CoreIPC::MessageReceiver {
    4848public:
    49     static const Type APIType = TypeKeyValueStorageManager;
    50 
    5149    static const char* supplementName();
    5250
     
    6361private:
    6462    explicit WebKeyValueStorageManagerProxy(WebContext*);
    65 
    66     virtual Type type() const { return APIType; }
    6763
    6864    void didGetKeyValueStorageOrigins(const Vector<SecurityOriginData>&, uint64_t callbackID);
  • trunk/Source/WebKit2/UIProcess/WebMediaCacheManagerProxy.h

    r141658 r147403  
    4343typedef GenericCallback<WKArrayRef> ArrayCallback;
    4444
    45 class WebMediaCacheManagerProxy : public APIObject, public WebContextSupplement, private CoreIPC::MessageReceiver {
     45class WebMediaCacheManagerProxy : public TypedAPIObject<APIObject::TypeMediaCacheManager>, public WebContextSupplement, private CoreIPC::MessageReceiver {
    4646public:
    47     static const Type APIType = TypeMediaCacheManager;
    48 
    4947    static const char* supplementName();
    5048
     
    6159private:
    6260    explicit WebMediaCacheManagerProxy(WebContext*);
    63 
    64     virtual Type type() const { return APIType; }
    6561
    6662    void didGetHostnamesWithMediaCache(const Vector<String>&, uint64_t callbackID);
  • trunk/Source/WebKit2/UIProcess/WebNavigationData.h

    r128683 r147403  
    3333namespace WebKit {
    3434
    35 class WebNavigationData : public APIObject {
     35class WebNavigationData : public TypedAPIObject<APIObject::TypeNavigationData> {
    3636public:
    37     static const Type APIType = TypeNavigationData;
    38 
    3937    static PassRefPtr<WebNavigationData> create(const WebNavigationDataStore& store)
    4038    {
     
    5149    explicit WebNavigationData(const WebNavigationDataStore&);
    5250
    53     virtual Type type() const { return APIType; }
    54 
    5551    WebNavigationDataStore m_store;
    5652};
  • trunk/Source/WebKit2/UIProcess/WebNetworkInfoManagerProxy.h

    r141366 r147403  
    3939class WebNetworkInfo;
    4040
    41 class WebNetworkInfoManagerProxy : public APIObject, private CoreIPC::MessageReceiver {
     41class WebNetworkInfoManagerProxy : public TypedAPIObject<APIObject::TypeNetworkInfoManager>, private CoreIPC::MessageReceiver {
    4242public:
    43     static const Type APIType = TypeNetworkInfoManager;
    44 
    4543    static PassRefPtr<WebNetworkInfoManagerProxy> create(WebContext*);
    4644    virtual ~WebNetworkInfoManagerProxy();
     
    5553private:
    5654    explicit WebNetworkInfoManagerProxy(WebContext*);
    57 
    58     virtual Type type() const { return APIType; }
    5955
    6056    // CoreIPC::MessageReceiver
  • trunk/Source/WebKit2/UIProcess/WebOpenPanelResultListenerProxy.h

    r128683 r147403  
    3636class WebPageProxy;
    3737
    38 class WebOpenPanelResultListenerProxy : public APIObject {
     38class WebOpenPanelResultListenerProxy : public TypedAPIObject<APIObject::TypeFramePolicyListener> {
    3939public:
    40     static const Type APIType = TypeFramePolicyListener;
    41 
    4240    static PassRefPtr<WebOpenPanelResultListenerProxy> create(WebPageProxy* page)
    4341    {
     
    5553    explicit WebOpenPanelResultListenerProxy(WebPageProxy*);
    5654
    57     virtual Type type() const { return APIType; }
    58 
    5955    RefPtr<WebPageProxy> m_page;
    6056};
  • trunk/Source/WebKit2/UIProcess/WebPageGroup.h

    r131281 r147403  
    3939class WebPageProxy;
    4040
    41 class WebPageGroup : public APIObject {
     41class WebPageGroup : public TypedAPIObject<APIObject::TypePageGroup> {
    4242public:
    43     static const Type APIType = TypePageGroup;
    44 
    4543    static PassRefPtr<WebPageGroup> create(const String& identifier = String(), bool visibleToInjectedBundle = true, bool visibleToHistoryClient = true);
    4644    static WebPageGroup* get(uint64_t pageGroupID);
     
    6967    WebPageGroup(const String& identifier, bool visibleToInjectedBundle, bool visibleToHistoryClient);
    7068
    71     virtual Type type() const { return APIType; }
    72    
    7369    template<typename MessageType> void sendToAllProcessesInGroup(const MessageType&, uint64_t destinationID);
    7470
  • trunk/Source/WebKit2/UIProcess/WebPageProxy.h

    r146355 r147403  
    230230
    231231class WebPageProxy
    232     : public APIObject
     232    : public TypedAPIObject<APIObject::TypePage>
    233233#if ENABLE(INPUT_TYPE_COLOR)
    234234    , public WebColorChooserProxy::Client
     
    237237    , public CoreIPC::MessageReceiver {
    238238public:
    239     static const Type APIType = TypePage;
    240239
    241240    static PassRefPtr<WebPageProxy> create(PageClient*, PassRefPtr<WebProcessProxy>, WebPageGroup*, uint64_t pageID);
     
    778777private:
    779778    WebPageProxy(PageClient*, PassRefPtr<WebProcessProxy>, WebPageGroup*, uint64_t pageID);
    780 
    781     virtual Type type() const { return APIType; }
    782779
    783780    // CoreIPC::MessageReceiver
  • trunk/Source/WebKit2/UIProcess/WebPreferences.cpp

    r131825 r147403  
    4343
    4444WebPreferences::WebPreferences(const WebPreferences& other)
    45     : APIObject()
    46     , m_store(other.m_store)
     45    : m_store(other.m_store)
    4746{
    4847    platformInitializeStore();
  • trunk/Source/WebKit2/UIProcess/WebPreferences.h

    r131825 r147403  
    4242class WebPageGroup;
    4343
    44 class WebPreferences : public APIObject {
     44class WebPreferences : public TypedAPIObject<APIObject::TypePreferences> {
    4545public:
    46     static const Type APIType = TypePreferences;
    47 
    4846    static PassRefPtr<WebPreferences> create()
    4947    {
     
    8583    void platformInitializeStore();
    8684
    87     virtual Type type() const { return APIType; }
    88 
    8985    void update();
    9086
  • trunk/Source/WebKit2/UIProcess/WebResourceCacheManagerProxy.h

    r141658 r147403  
    4545typedef GenericCallback<WKArrayRef> ArrayCallback;
    4646
    47 class WebResourceCacheManagerProxy : public APIObject, public WebContextSupplement, private CoreIPC::MessageReceiver {
     47class WebResourceCacheManagerProxy : public TypedAPIObject<APIObject::TypeCacheManager>, public WebContextSupplement, private CoreIPC::MessageReceiver {
    4848public:
    49     static const Type APIType = TypeCacheManager;
    50 
    5149    static const char* supplementName();
    5250
     
    6361private:
    6462    explicit WebResourceCacheManagerProxy(WebContext*);
    65 
    66     virtual Type type() const { return APIType; }
    6763
    6864    // WebContextSupplement
  • trunk/Source/WebKit2/UIProcess/WebTextChecker.h

    r96858 r147403  
    3636class WebPageProxy;
    3737
    38 class WebTextChecker : public APIObject {
     38class WebTextChecker : public TypedAPIObject<APIObject::TypeTextChecker> {
    3939public:
    40     static const Type APIType = TypeTextChecker;
    41 
    4240    static WebTextChecker* shared();
    4341
     
    5452    WebTextChecker();
    5553
    56     virtual Type type() const { return APIType; }
    57 
    5854    WebTextCheckerClient m_client;
    5955};
  • trunk/Source/WebKit2/UIProcess/WebVibrationProxy.h

    r141366 r147403  
    3838class WebPageProxy;
    3939
    40 class WebVibrationProxy : public APIObject, private CoreIPC::MessageReceiver {
     40class WebVibrationProxy : public TypedAPIObject<APIObject::TypeVibration>, private CoreIPC::MessageReceiver {
    4141public:
    42     static const Type APIType = TypeVibration;
    43 
    4442    static PassRefPtr<WebVibrationProxy> create(WebPageProxy*);
    4543    virtual ~WebVibrationProxy();
     
    5149private:
    5250    explicit WebVibrationProxy(WebPageProxy*);
    53 
    54     virtual Type type() const { return APIType; }
    5551
    5652    // CoreIPC::MessageReceiver
  • trunk/Source/WebKit2/UIProcess/efl/WebPopupItemEfl.h

    r143275 r147403  
    3333namespace WebKit {
    3434
    35 class WebPopupItemEfl : public APIObject {
     35class WebPopupItemEfl : public TypedAPIObject<APIObject::TypePopupMenuItem> {
    3636public:
    37     static const Type APIType = TypePopupMenuItem;
    38 
    3937    static PassRefPtr<WebPopupItemEfl> create(const WebPopupItem& data)
    4038    {
     
    5856    explicit WebPopupItemEfl(const WebPopupItem&);
    5957
    60     virtual Type type() const { return APIType; }
    61 
    6258    WebPopupItem m_data;
    6359};
  • trunk/Source/WebKit2/UIProcess/efl/WebView.h

    r146265 r147403  
    4747namespace WebKit {
    4848
    49 class WebView : public APIObject, public PageClient {
     49class WebView : public TypedAPIObject<APIObject::TypeView>, public PageClient {
    5050public:
    51     static const Type APIType = TypeView;
    52 
    5351    virtual ~WebView();
    5452
     
    178176
    179177private:
    180     virtual Type type() const { return APIType; }
    181 
    182178    WebViewClient m_client;
    183179    EwkView* m_ewkView;
  • trunk/Source/WebKit2/UIProcess/soup/WebSoupRequestManagerProxy.h

    r141658 r147403  
    3535class WebData;
    3636
    37 class WebSoupRequestManagerProxy : public APIObject, public WebContextSupplement, private CoreIPC::MessageReceiver {
     37class WebSoupRequestManagerProxy : public TypedAPIObject<APIObject::TypeSoupRequestManager>, public WebContextSupplement, private CoreIPC::MessageReceiver {
    3838public:
    39     static const Type APIType = TypeSoupRequestManager;
    40 
    4139    static const char* supplementName();
    4240
     
    5957    WebSoupRequestManagerProxy(WebContext*);
    6058
    61     virtual Type type() const { return APIType; }
    62 
    6359    // WebContextSupplement
    6460    virtual void contextDestroyed() OVERRIDE;
  • trunk/Source/WebKit2/WebProcess/InjectedBundle/DOM/InjectedBundleNodeHandle.h

    r146154 r147403  
    4545class WebImage;
    4646
    47 class InjectedBundleNodeHandle : public APIObject {
     47class InjectedBundleNodeHandle : public TypedAPIObject<APIObject::TypeBundleNodeHandle> {
    4848public:
    49     static const Type APIType = TypeBundleNodeHandle;
    50 
    5149    static PassRefPtr<InjectedBundleNodeHandle> getOrCreate(JSContextRef, JSObjectRef);
    5250    static PassRefPtr<InjectedBundleNodeHandle> getOrCreate(WebCore::Node*);
     
    8078    InjectedBundleNodeHandle(WebCore::Node*);
    8179
    82     virtual Type type() const { return APIType; }
    83 
    8480    RefPtr<WebCore::Node> m_node;
    8581};
  • trunk/Source/WebKit2/WebProcess/InjectedBundle/DOM/InjectedBundleRangeHandle.h

    r142900 r147403  
    4040class InjectedBundleScriptWorld;
    4141
    42 class InjectedBundleRangeHandle : public APIObject {
     42class InjectedBundleRangeHandle : public TypedAPIObject<APIObject::TypeBundleRangeHandle> {
    4343public:
    44     static const Type APIType = TypeBundleRangeHandle;
    45 
    4644    static PassRefPtr<InjectedBundleRangeHandle> getOrCreate(JSContextRef, JSObjectRef);
    4745    static PassRefPtr<InjectedBundleRangeHandle> getOrCreate(WebCore::Range*);
     
    5553    InjectedBundleRangeHandle(WebCore::Range*);
    5654
    57     virtual Type type() const { return APIType; }
    58 
    5955    RefPtr<WebCore::Range> m_range;
    6056};
  • trunk/Source/WebKit2/WebProcess/InjectedBundle/InjectedBundle.h

    r145784 r147403  
    7878class WebPageGroupProxy;
    7979
    80 class InjectedBundle : public APIObject {
     80class InjectedBundle : public TypedAPIObject<APIObject::TypeBundle> {
    8181public:
    82     static const Type APIType = TypeBundle;
    83 
    8482    static PassRefPtr<InjectedBundle> create(const String& path)
    8583    {
     
    180178    explicit InjectedBundle(const String&);
    181179
    182     virtual Type type() const { return APIType; }
    183 
    184180    String m_path;
    185181    PlatformBundle m_platformBundle; // This is leaked right now, since we never unload the bundle/module.
  • trunk/Source/WebKit2/WebProcess/InjectedBundle/InjectedBundleBackForwardList.h

    r95901 r147403  
    3636class InjectedBundleBackForwardListItem;
    3737
    38 class InjectedBundleBackForwardList : public APIObject {
     38class InjectedBundleBackForwardList : public TypedAPIObject<APIObject::TypeBundleBackForwardList> {
    3939public:
    40     static const Type APIType = TypeBundleBackForwardList;
    41 
    4240    static PassRefPtr<InjectedBundleBackForwardList> create(WebPage* page)
    4341    {
     
    5654    InjectedBundleBackForwardList(WebPage* page) : m_page(page) { }
    5755
    58     virtual Type type() const { return APIType; }
    59 
    6056    WebPage* m_page;
    6157};
  • trunk/Source/WebKit2/WebProcess/InjectedBundle/InjectedBundleBackForwardListItem.h

    r145789 r147403  
    3535class WebPageProxy;
    3636
    37 class InjectedBundleBackForwardListItem : public APIObject {
     37class InjectedBundleBackForwardListItem : public TypedAPIObject<APIObject::TypeBundleBackForwardListItem> {
    3838public:
    39     static const Type APIType = TypeBundleBackForwardListItem;
    40 
    4139    static PassRefPtr<InjectedBundleBackForwardListItem> create(PassRefPtr<WebCore::HistoryItem> item)
    4240    {
     
    6260    InjectedBundleBackForwardListItem(PassRefPtr<WebCore::HistoryItem> item) : m_item(item) { }
    6361
    64     virtual Type type() const { return APIType; }
    65 
    6662    RefPtr<WebCore::HistoryItem> m_item;
    6763};
  • trunk/Source/WebKit2/WebProcess/InjectedBundle/InjectedBundleDOMWindowExtension.h

    r115128 r147403  
    4141class WebFrame;
    4242
    43 class InjectedBundleDOMWindowExtension : public APIObject {
     43class InjectedBundleDOMWindowExtension : public TypedAPIObject<APIObject::TypeBundleDOMWindowExtension> {
    4444public:
    45     static const Type APIType = TypeBundleDOMWindowExtension;
    46 
    4745    static PassRefPtr<InjectedBundleDOMWindowExtension> create(WebFrame*, InjectedBundleScriptWorld*);
    4846    static InjectedBundleDOMWindowExtension* get(WebCore::DOMWindowExtension*);
     
    5452
    5553private:
    56     virtual Type type() const { return APIType; }
    57 
    5854    InjectedBundleDOMWindowExtension(WebFrame*, InjectedBundleScriptWorld*);
    5955
  • trunk/Source/WebKit2/WebProcess/InjectedBundle/InjectedBundleHitTestResult.h

    r97810 r147403  
    3838class WebFrame;
    3939
    40 class InjectedBundleHitTestResult : public APIObject {
     40class InjectedBundleHitTestResult : public TypedAPIObject<APIObject::TypeBundleHitTestResult> {
    4141public:
    42     static const Type APIType = TypeBundleHitTestResult;
    43 
    4442    static PassRefPtr<InjectedBundleHitTestResult> create(const WebCore::HitTestResult&);
    4543
     
    6866    }
    6967
    70     virtual Type type() const { return APIType; }
    71 
    7268    WebCore::HitTestResult m_hitTestResult;
    7369};
  • trunk/Source/WebKit2/WebProcess/InjectedBundle/InjectedBundleNavigationAction.h

    r95901 r147403  
    4444class WebFrame;
    4545
    46 class InjectedBundleNavigationAction : public APIObject {
     46class InjectedBundleNavigationAction : public TypedAPIObject<APIObject::TypeBundleNavigationAction> {
    4747public:
    48     static const Type APIType = TypeBundleNavigationAction;
    49 
    5048    static PassRefPtr<InjectedBundleNavigationAction> create(WebFrame*, const WebCore::NavigationAction&, PassRefPtr<WebCore::FormState>);
    5149
     
    6260    InjectedBundleNavigationAction(WebFrame*, const WebCore::NavigationAction&, PassRefPtr<WebCore::FormState>);
    6361
    64     virtual Type type() const { return APIType; }
    65 
    6662    WebCore::NavigationType m_navigationType;
    6763    WebEvent::Modifiers m_modifiers;
  • trunk/Source/WebKit2/WebProcess/InjectedBundle/InjectedBundleScriptWorld.h

    r95901 r147403  
    3737namespace WebKit {
    3838
    39 class InjectedBundleScriptWorld : public APIObject {
     39class InjectedBundleScriptWorld : public TypedAPIObject<APIObject::TypeBundleScriptWorld> {
    4040public:
    41     static const Type APIType = TypeBundleScriptWorld;
    42 
    4341    static PassRefPtr<InjectedBundleScriptWorld> create();
    4442    static PassRefPtr<InjectedBundleScriptWorld> getOrCreate(WebCore::DOMWrapperWorld*);
     
    5452    InjectedBundleScriptWorld(PassRefPtr<WebCore::DOMWrapperWorld>);
    5553
    56     virtual Type type() const { return APIType; }
    57 
    5854    RefPtr<WebCore::DOMWrapperWorld> m_world;
    5955};
  • trunk/Source/WebKit2/WebProcess/WebPage/PageOverlay.h

    r145731 r147403  
    4141class WebPage;
    4242
    43 class PageOverlay : public APIObject {
     43class PageOverlay : public TypedAPIObject<APIObject::TypeBundlePageOverlay> {
    4444public:
    4545    class Client {
     
    5454        virtual bool mouseEvent(PageOverlay*, const WebMouseEvent&) = 0;
    5555    };
    56 
    57     static const Type APIType = TypeBundlePageOverlay;
    5856
    5957    static PassRefPtr<PageOverlay> create(Client*);
     
    7775
    7876private:
    79     // APIObject
    80     virtual Type type() const { return APIType; }
    81 
    8277    WebCore::IntRect bounds() const;
    8378
  • trunk/Source/WebKit2/WebProcess/WebPage/WebFrame.h

    r145914 r147403  
    5656class WebPage;
    5757
    58 class WebFrame : public APIObject {
     58class WebFrame : public TypedAPIObject<APIObject::TypeBundleFrame> {
    5959public:
    60     static const Type APIType = TypeBundleFrame;
    61 
    6260    static PassRefPtr<WebFrame> createMainFrame(WebPage*);
    6361    static PassRefPtr<WebFrame> createSubframe(WebPage*, const String& frameName, WebCore::HTMLFrameOwnerElement*);
     
    148146    void init(WebPage*, const String& frameName, WebCore::HTMLFrameOwnerElement*);
    149147
    150     virtual Type type() const { return APIType; }
    151 
    152148    WebCore::Frame* m_coreFrame;
    153149
  • trunk/Source/WebKit2/WebProcess/WebPage/WebInspector.h

    r147004 r147403  
    4444struct WebPageCreationParameters;
    4545
    46 class WebInspector : public APIObject {
     46class WebInspector : public TypedAPIObject<APIObject::TypeBundleInspector> {
    4747public:
    48     static const Type APIType = TypeBundleInspector;
    49 
    5048    static PassRefPtr<WebInspector> create(WebPage*, WebCore::InspectorFrontendChannel*);
    5149
     
    8785
    8886    explicit WebInspector(WebPage*, WebCore::InspectorFrontendChannel*);
    89 
    90     virtual Type type() const { return APIType; }
    9187
    9288    // Called from WebInspectorClient
  • trunk/Source/WebKit2/WebProcess/WebPage/WebPage.h

    r147260 r147403  
    167167typedef Vector<RefPtr<PageOverlay> > PageOverlayList;
    168168
    169 class WebPage : public APIObject, public CoreIPC::MessageReceiver, public CoreIPC::MessageSender<WebPage> {
     169class WebPage : public TypedAPIObject<APIObject::TypeBundlePage>, public CoreIPC::MessageReceiver, public CoreIPC::MessageSender<WebPage> {
    170170public:
    171     static const Type APIType = TypeBundlePage;
    172 
    173171    static PassRefPtr<WebPage> create(uint64_t pageID, const WebPageCreationParameters&);
    174172    virtual ~WebPage();
     
    654652    WebPage(uint64_t pageID, const WebPageCreationParameters&);
    655653
    656     virtual Type type() const { return APIType; }
    657 
    658654    void platformInitialize();
    659655
  • trunk/Source/WebKit2/WebProcess/WebPage/WebPageGroupProxy.h

    r141472 r147403  
    4242namespace WebKit {
    4343
    44 class WebPageGroupProxy : public APIObject {
     44class WebPageGroupProxy : public TypedAPIObject<APIObject::TypeBundlePageGroup> {
    4545public:
    46     static const Type APIType = TypeBundlePageGroup;
    47 
    4846    static PassRefPtr<WebPageGroupProxy> create(const WebPageGroupData&);
    4947    virtual ~WebPageGroupProxy();
     
    5856private:
    5957    WebPageGroupProxy(const WebPageGroupData&);
    60 
    61     virtual Type type() const { return APIType; }
    6258
    6359    void addUserStyleSheet(const WebCore::UserStyleSheet&);
Note: See TracChangeset for help on using the changeset viewer.