Return a Message object for given id.

        :param id: The id of the message object to return.
769043
def get_message(self, id):
        
        url = self._base_url + "/3/message/{0}".format(id)
        resp = self._send_request(url)
        return Message(resp, self)
226272
def query_by_id(self, id):
        
        return json.loads(self._get(UrlEncoded(str(id))).body.read().decode('utf-8'))
1050769
def request(self, id, **kwargs):
        
        data = self.get('requests', id, **kwargs)
        return data
25852
def get(id)
      return unless id
      with_redis { |redis| redis.get(redis_key_for(id)).try { |data| load(data) } }
    end
425643
def defines(self, id, domain='messages'):
        
        assert isinstance(id, (str, unicode))
        assert isinstance(domain, (str, unicode))

        return id in self.messages.get(domain, {})
448870
def gotMessage(self, message_id, message):
        
        d = defer.maybeDeferred(self._handle_message, message)
        d.addCallback(self.generate_response)
        d.addCallback(lambda resp: self.reply(message_id, resp))
        return d
1140860
def get(self, id):
        
        url = self._url('%s' % (id))
        return self.client.get(url)
10039
def get(self, id, param):
        
        assert isinstance(id, basestring)
        assert isinstance(param, basestring)
        return self.params_.get(param, {}).get(id)
87786
def get_message_type_by_id(self, message_type_id):
        
        self._validate_uuid(message_type_id)

        url = "/notification/v1/message-type/{}".format(message_type_id)
        response = NWS_DAO().getURL(url, self._write_headers())
        if response.status != 200:
            raise DataFailureException(url, response.status, response.data)

        data = json.loads(response.data)
        return self._message_type_from_json(data.get("MessageType"))
3440
public function getMessage($id = '')
    {
        $message = [];
        if (is_array($this->messages) == true) {
            foreach($this ->messages as $msg) {
                if ($msg['index'] == $id) {
                    $message = $msg;
                    break;
                }
            }
        }

        if (is_array($message) === true) {
            // Get the message body but do not mark as read
            $message['body'] = quoted_printable_decode(imap_fetchbody($this->conn, $message['index'], FT_PEEK));
        }

        return $message;
    }
819343
public static MessageBean getMessage(final String id, final String... params) {
        if (!msgs.containsKey(id)) {
            throw new IllegalArgumentException("Message for ID '" + id + "' not found");
        }
        final String msg = MessageFormat.format(msgs.getString(id), (Object[]) params);
        MessageBean.Type type = null;
        switch (id.substring(id.length() - 1)) {
            case "F":
                type = MessageBean.Type.FATAL;
                break;
            case "E":
                type = MessageBean.Type.ERROR;
                break;
            case "W":
                type = MessageBean.Type.WARN;
                break;
            case "I":
                type = MessageBean.Type.INFO;
                break;
            case "D":
                type = MessageBean.Type.DEBUG;
                break;
        }
        return new MessageBean(id, type, msg, null);
    }
954135
def get(cls, id, api=None):
        
        id = Transform.to_resource(id)
        api = api if api else cls._API
        if 'get' in cls._URL:
            extra = {'resource': cls.__name__, 'query': {'id': id}}
            logger.info('Fetching {} resource'.format(cls), extra=extra)
            resource = api.get(url=cls._URL['get'].format(id=id)).json()
            return cls(api=api, **resource)
        else:
            raise SbgError('Unable to fetch resource!')
38407
def get(self, id):
        
        id = self.as_id(id)
        url = '%s/%s' % (self, id)
        response = self.http.get(url, auth=self.auth)
        response.raise_for_status()
        return response.json()
1109752
def get_object(self, ObjectClass, id):
        
        try:
            object = ObjectClass.objects.get(id=id)
        except (ObjectClass.DoesNotExist, ObjectClass.MultipleObjectsReturned):
            object = None
        return object
841837
def _get_one(self, id):
        
        try:
            return self._to_dict(models.User.objects.get(pk=id))
        except models.User.DoesNotExist:
            raise errors.NotFound()
716736
def get_message_by_id(self, message_id):
        
        result = self.wapi_functions.getMessageById(message_id)

        if result:
            result = factory_message(result, self)

        return result
1276878
def find_by_id(self, _id, **kwargs):
        

        if type(_id) == dict and _id.get("_id"):
            return self.find_one({"_id": ObjectId(_id["_id"])}, **kwargs)

        return self.find_one({"_id": ObjectId(_id)}, **kwargs)