Push에 필요한 GCM ID/Apple Device ID 를 등록

Namespace: Matrix.Component
Assembly: MatrixGames (in MatrixGames.dll)

void SetPushID( 
int appStoreType
string regID
Callback<SetPushIDResponse> cb 
)
This language is not supported or no code example is available.

Parameters

appStoreType

Type: int

앱스토어 타입. 1 - apple, 2 - google play

regID

Type: string

gcm registration ID/apns device id.

cb

Type: Callback<SetPushIDResponse>

Callback function

Return Value

  • On Successful -

    cb.result: 0.

    cb.cause: "OK"

  • On Error -

    cb.result: 0가 아닌 integer 값

    cb.cause: 상세 에러 메세지

Push에 필요한 GCM ID/Apple Device ID 를 등록하는 Method.
	
  using UnityEngine;
  using System;
  using System.Collections;
  using System.Collections.Generic;
  using Matrix;
 
  static void onPushSetPushIDTest(Matrix.CallbackInfo<Matrix.Domain.Push.SetPushIDResponse> info)
  {
      Debug.Log("onPushSetPushIDTest Called");
      Debug.Log("result: " + info.result);
 
      if (info.result == 0)
      {
         /* result 값만 있고 Response Data는 없음 */
         Debug.log("Success");
      }
  }
 
  static void onPushSetPushIDTest()
  {
      IMatrix API = MatrixManager.Instance;
      Debug.Log("[onPushSetPushIDTest]");
 
      API.Push.SetPushID(2, "8739238182", onPushSetPushIDTest);
  }
 					

.NET Framework

Supported in: 4.5, 4, 3.5, 3.0, 2.0, 1.1, 1.0

.NET Compact Framework

Supported in: 3.5, 2.0, 1.0

XNA Framework

Supported in: 3.0, 2.0, 1.0