# -*- coding: utf-8 -*-
#
# Copyright (C) 2010-2016 .
# Guijin Ding, dingguijin@gmail.com
#
#

from .basehandler import BaseHandler

from ppmessage.api.error import API_ERR
from ppmessage.core.constant import API_LEVEL
from ppmessage.backend.amd import AmdDelegate

import json
import logging

class PPGetUserMatchedMethod(BaseHandler):
    
    def initialize(self):
        self.addPermission(app_uuid=True)
        self.addPermission(api_level=API_LEVEL.PPCONSOLE)
        self.addPermission(api_level=API_LEVEL.THIRD_PARTY_CONSOLE)
        return
    
    def _Task(self):
        super(PPGetUserMatchedMethod, self)._Task()
        _ret = getReturnData()
        _ret["list"] = AmdDelegate().get_user_matched_method()
        return
