Skip to main content

By clicking Submit, you agree to the developerWorks terms of use.

The first time you sign into developerWorks, a profile is created for you. Select information in your developerWorks profile is displayed to the public, but you may edit the information at any time. Your first name, last name (unless you choose to hide them), and display name will accompany the content that you post.

All information submitted is secure.

  • Close [x]

The first time you sign in to developerWorks, a profile is created for you, so you need to choose a display name. Your display name accompanies the content you post on developerworks.

Please choose a display name between 3-31 characters. Your display name must be unique in the developerWorks community and should not be your email address for privacy reasons.

By clicking Submit, you agree to the developerWorks terms of use.

All information submitted is secure.

  • Close [x]

Intro to XPCOM, Part 4

Component development

Return to article

#ifndef _MOZGPS_H
#define _MOZGPS_H

#include "mozIGPS.h"

#define MOZ_GPS_NMEA_CONTRACTID "@ficticious.org/GPS/NMEA;1"
#define MOZ_GPS_NMEA_CLASSNAME "GPS Support for NMEA"
#define MOZ_GPS_NMEA_CID  {0x1bdc2ee1,0xe92a,0x11d4,{0xbc,0xc0,0x0,0x60,0x8,0x92,0x96,0xcb}}

#define MOZ_GPS_TAIP_CONTRACTID "@ficticious.org/GPS/TAIP;1"
#define MOZ_GPS_TAIP_CLASSNAME "GPS Support for TAIP"
#define MOZ_GPS_TAIP_CID  {0x1bdc2ee2,0xe92a,0x11d4,{0xbc,0xc0,0x0,0x60,0x8,0x92,0x96,0xcb}}

#define MOZ_GPS_TSIP_CONTRACTID "@ficticious.org/GPS/TSIP;1"
#define MOZ_GPS_TSIP_CLASSNAME "GPS Support for TSIP"
#define MOZ_GPS_TSIP_CID  {0x1bdc2ee3,0xe92a,0x11d4,{0xbc,0xc0,0x0,0x60,0x8,0x92,0x96,0xcb}}

/* NMEA */
class mozGPSNMEAImpl : public mozIGPS
{
public:
  NS_DECL_ISUPPORTS
  NS_DECL_MOZIGPS

  mozGPSNMEAImpl();
  virtual ~mozGPSNMEAImpl();
  /* additional members */
};

/* TSIP */
class mozGPSTSIPImpl : public mozIGPS
{
public:
  NS_DECL_ISUPPORTS
  NS_DECL_MOZIGPS

  mozGPSTSIPImpl();
  virtual ~mozGPSTSIPImpl();
  /* additional members */
};

/* TAIP */
class mozGPSTAIPImpl : public mozIGPS
{
public:
  NS_DECL_ISUPPORTS
  NS_DECL_MOZIGPS

  mozGPSTAIPImpl();
  virtual ~mozGPSTAIPImpl();
  /* additional members */
};

#endif

Return to article