Esempio n. 1
0
    def __init__(self, **kwargs):
        dictionary = kwargs.pop("dictionary", None)
        Object.__init__(self, **kwargs)

        if dictionary:
            for attribute in self.required_attributes:
                setattr(self, attribute, dictionary[attribute])
            for attribute in self.optional_attributes:
                if attribute in dictionary:
                    setattr(self, attribute, dictionary[attribute])
Esempio n. 2
0
    def __init__(self, **kwargs):
        dictionary = kwargs.pop("dictionary", None)
        Object.__init__(self, **kwargs)

        if dictionary:
            for attribute in self.required_attributes:
                setattr(self, attribute, dictionary[attribute])
            for attribute in self.optional_attributes:
                if attribute in dictionary:
                    setattr(self, attribute, dictionary[attribute])
 def __init__(self, **kwargs):
     logging.info("sipMessage() __init__ sipMessage")
     print 'sipMessage() __init__ sipMessage'
     self.hasSDP             = False
     self.sipHeaderInfo      = {}
     self.sipMsgSdpInfo      = {}            
     self.sipMsgMethodInfo   = ''
     self.sipMsgCallId       = ''
     self.sipMsgCallId = kwargs
     assert "sipMsgCallId" in kwargs
     Object.__init__(self, **kwargs)
Esempio n. 4
0
 def __init__(self, source_url):
     ParseObject.__init__(self)
 
     obj = Content._embedly_client.oembed(source_url)
     
     self.object_description = obj['description'] if 'description' in obj else None
     self.title = obj['title'] if 'title' in obj else None
     self.url = source_url
     self.thumbnail_url = obj['thumbnail_url'] if 'thumbnail_url' in obj else None
     self.provider_name = obj['provider_name'] if 'provider_name' in obj else None
     self.type = obj['type'] if 'type' in obj else 'unknown'
Esempio n. 5
0
    def __init__(self, source_url):
        ParseObject.__init__(self)

        obj = Content._embedly_client.oembed(source_url)

        self.object_description = obj[
            'description'] if 'description' in obj else None
        self.title = obj['title'] if 'title' in obj else None
        self.url = source_url
        self.thumbnail_url = obj[
            'thumbnail_url'] if 'thumbnail_url' in obj else None
        self.provider_name = obj[
            'provider_name'] if 'provider_name' in obj else None
        self.type = obj['type'] if 'type' in obj else 'unknown'
 def __init__(self, **kwargs):
     logging.info("sipCall() New sipCall object created()")
     print 'sipCall() New sipCall object created()'
     self.sipCallID = kwargs
     assert "sipCallID" in kwargs
     Object.__init__(self, **kwargs)