/* Copyright 2009 Palm, Inc.  All rights reserved. */

var TelephonyMojoService = Class.create( {
  initialize: function() {
  },
  
  mdnQuery: function(callback, sceneController) {
    return sceneController.serviceRequest(TelephonyMojoService.identifier, {
      method: 'phoneNumberQuery',
			parameters: { },
			onSuccess: callback,
			onFailure: callback
    });
  },
  
  msidQuery: function(callback, sceneController) {
    return sceneController.serviceRequest(TelephonyMojoService.identifier, {
      method: 'activationInfoQuery',
			parameters: { },
			onSuccess: callback,
			onFailure: callback
    });
  },
  
  imeiQuery: function(callback, sceneController) {
    return sceneController.serviceRequest(TelephonyMojoService.identifier, {
      method: 'imeiQuery',
			parameters: { },
			onSuccess: callback,
			onFailure: callback
    });
  },
  
  meidQuery: function(callback, sceneController) {
    return sceneController.serviceRequest(TelephonyMojoService.identifier, {
      method: 'meidQuery',
			parameters: { },
			onSuccess: callback,
			onFailure: callback
    });
  },
  
  iccidQuery: function(callback, sceneController) {
    return sceneController.serviceRequest(TelephonyMojoService.identifier, {
      method: 'iccidQuery',
			parameters: { },
			onSuccess: callback,
			onFailure: callback
    });
  },
  
  esnQuery: function(callback, sceneController) {
    return sceneController.serviceRequest(TelephonyMojoService.identifier, {
      method: 'esnQuery',
			parameters: { },
			onSuccess: callback,
			onFailure: callback
    });
  },
  
  prlversionQuery: function(callback, sceneController) {
    return sceneController.serviceRequest(TelephonyMojoService.identifier, {
      method: 'prlversionQuery',
			parameters: { },
			onSuccess: callback,
			onFailure: callback
    });
  },
  
//  carrierQuery: function(callback, sceneController) {
//  	return sceneController.serviceRequest(TelephonyMojoService.identifier, {
//      method: 'networkStatusQuery',
//			parameters: { },
//			onSuccess: callback,
//			onFailure: callback
//    });
//  },
   
  firmwareQuery: function(callback, sceneController) {
  	return sceneController.serviceRequest(TelephonyMojoService.identifier, {
      method: 'modemfirmwareversionQuery',
			parameters: { },
			onSuccess: callback,
			onFailure: callback
    });
  },
  
  pdpSlotQuery: function(callback, sceneController) {
  	return sceneController.serviceRequest(TelephonyMojoService.identifier, {
      method: 'pdpSlotQuery',
			parameters: { },
			onSuccess: callback,
			onFailure: callback
    });
  },

  pdpProfileQuery: function(pdpSlot, callback, sceneController) {
  	return sceneController.serviceRequest(TelephonyMojoService.identifier, {
      method: 'pdpProfileQuery',
			parameters: { 'slot':pdpSlot },
			onSuccess: callback,
			onFailure: callback
    });
  },
  
  getBtPanRouteStatus: function(callback, sceneController) {
  	return sceneController.serviceRequest('palm://com.palm.connectionmanager', {
      method: 'getbtpanroutestatus',
			parameters: { 'subscribe':true },
			onSuccess: callback,
			onFailure: callback
    });
  }

	

});

TelephonyMojoService.identifier = 'palm://com.palm.telephony';
