def _initialize(self,result): # this is called by initialize_element; # putting it here to ensure method resolution order Vertex._initialize(self,result) element_type = self._get_element_type() self._set_property_data(result) self._index = self._get_index(element_type)
def _initialize(self, result): # this is called by the initialize_element util; # putting it here to ensure method resolution order. # initialize all non-DB properties here Vertex._initialize(self,result) self._initialized = False self._set_property_data() self._initialized = True
def _initialize(self, result): # this is called by initialize_element; # putting it here to ensure method resolution order Vertex._initialize(self, result) element_type = self._get_element_type() self._set_default_values() self._set_property_data() self._index = self._get_index(element_type)
def _initialize(self, result): """ Initializes the element. Initialize all non-DB attributes here. :param result: Result object. :type result: Result :rtype: None ..note:: Called by _create, _update, and utils.initialize_element. """ Vertex._initialize(self,result) self._initialized = False self._set_property_data() self._initialized = True
def test_ascii_encoding_index_lookup2(self): # http://stackoverflow.com/questions/23057915/rexster-bulbs-unicode-node-property-node-created-but-not-found # using default index name because that's what create_indexed_vertex() uses name = u"Université de Montréal" + bulbs.utils.to_string(random.random()) index_name = Vertex.get_index_name(self.vertices.client.config) self.vertices.client.config.set_logger(ERROR) self.vertices.index = self.indicesV.get_or_create(index_name) v1a = self.vertices.create(name=name) v1b = self.vertices.index.lookup(u"name", name) assert next(v1b).name == name
def test_ascii_encoding_index_lookup2(self): # http://stackoverflow.com/questions/23057915/rexster-bulbs-unicode-node-property-node-created-but-not-found # using default index name because that's what create_indexed_vertex() uses name = u'Université de Montréal' + bulbs.utils.to_string(random.random()) index_name = Vertex.get_index_name(self.vertices.client.config) self.vertices.client.config.set_logger(ERROR) self.vertices.index = self.indicesV.get_or_create(index_name) v1a = self.vertices.create(name=name) v1b = self.vertices.index.lookup(u"name", name) assert next(v1b).name == name
def test_ascii_encoding_index_lookup(self): # Fixed for Neo4j Server. Still having issues with Rexster... # https://github.com/espeed/bulbs/issues/117 # using default index name because that's what create_indexed_vertex() uses name = u'Aname M\xf6ller' + bulbs.utils.to_string(random.random()) index_name = Vertex.get_index_name(self.vertices.client.config) self.vertices.client.config.set_logger(ERROR) self.vertices.index = self.indicesV.get_or_create(index_name) v1a = self.vertices.create(name=name) v1b = self.vertices.index.lookup(u"name", name) assert next(v1b).name == name