void BuildingFactory::handleObjectReady(Object* object,DispatchClient* client) { InLoadingContainer* ilc = _getObject(object->getParentId()); if (! ilc) {//ILC sanity check... LOG(warning) << "Could not locate InLoadingContainer for object parent [" << object->getParentId() << "]"; return; } BuildingObject* building = dynamic_cast<BuildingObject*>(ilc->mObject); //this happens on load so no reason to update players gWorldManager->addObject(object,true); building->addCell(dynamic_cast<CellObject*>(object)); //LOG(info) << "BuildingFactory::handleObjectReady -> building load cell " << object->getId() << "for " << building->getId(); //LOG(info) << "loadcount : " << building->getLoadCount() << " : count : " << building->getCellList()->size(); if(building->getLoadCount() == (building->getCellList())->size()) { //LOG(info) << "BuildingFactory::handleObjectReady -> building loadcount done for " << building->getId(); if(!(_removeFromObjectLoadMap(building->getId()))) LOG(warning) << "Failed removing object from loadmap"; ilc->mOfCallback->handleObjectReady(building,ilc->mClient); mILCPool.free(ilc); } }
void BuildingFactory::handleObjectReady(Object* object,DispatchClient* client) { InLoadingContainer* ilc = _getObject(object->getParentId()); if (! ilc) {//ILC sanity check... gLogger->log(LogManager::WARNING,"BuildingFactory::handleObjectReady could not locate ILC for objectParentId:%I64u",object->getParentId()); return; } BuildingObject* building = dynamic_cast<BuildingObject*>(ilc->mObject); //this happens on load so no reason to update players gWorldManager->addObject(object,true); building->addCell(dynamic_cast<CellObject*>(object)); if(building->getLoadCount() == (building->getCellList())->size()) { if(!(_removeFromObjectLoadMap(building->getId()))) gLogger->log(LogManager::DEBUG,"BuildingFactory: Failed removing object from loadmap"); ilc->mOfCallback->handleObjectReady(building,ilc->mClient); mILCPool.free(ilc); } }
void InventoryFactory::handleObjectReady(Object* object,DispatchClient* client) { //we either have the ID of the inventory or of the player //the inventory of course is stored under its own Id InLoadingContainer* ilc = _getObject(object->getParentId()); assert(ilc && "InventoryFactory::handleObjectReady unable to find InLoadingContainer"); if (! ilc) { return; } Inventory* inventory = dynamic_cast<Inventory*>(ilc->mObject); gWorldManager->addObject(object,true); //for unequipped items only inventory->addObjectSecure(object); if(inventory->getObjectLoadCounter() == (inventory->getObjects())->size()) { gLogger->logMsgF("InventoryFactory: remove inventory %I64u from loadmap",MSG_HIGH,inventory->getId()); inventory->setLoadState(LoadState_Loaded); if(!(_removeFromObjectLoadMap(inventory->getId()))) gLogger->logMsg("InventoryFactory: Failed removing object from loadmap"); ilc->mOfCallback->handleObjectReady(inventory,ilc->mClient); mILCPool.free(ilc); } }
void HarvesterFactory::handleObjectReady(Object* object,DispatchClient* client) { //*ONLY* used to load resource containers //never used .... InLoadingContainer* ilc = _getObject(object->getParentId()); if (! ilc) {//ILC sanity check... LOG(warning) << "Could not locate InLoadingContainer for object parent [" << object->getParentId() << "]"; return; } HarvesterObject* harvester = dynamic_cast<HarvesterObject*>(ilc->mObject); //add res containers gWorldManager->addObject(object,true); if(harvester->decLoadCount() == 0) { if(!(_removeFromObjectLoadMap(harvester->getId()))) LOG(warning) << "Failed removing object from loadmap"; ilc->mOfCallback->handleObjectReady(harvester,ilc->mClient); mILCPool.free(ilc); } }
void ContainerObjectFactory::handleObjectReady(Object* object,DispatchClient* client) { InLoadingContainer* ilc = _getObject(object->getParentId()); if(!ilc) { //Crashbug patch: http://paste.swganh.org/viewp.php?id=20100627024455-d7efda0b4aebaa96b06438b2c42dfe6c LOG(WARNING) << "Failed to locate InLoadingContainer for parent id [" << object->getParentId() << "]"; return; } ilc->mLoadCounter--; Container* container = dynamic_cast<Container*>(ilc->mObject); // reminder: objects are owned by the global map, containers only keeps references // If object with same key already exist in world map, this object will be invalid. if (!gWorldManager->existObject(object)) { container->addObject(object); gWorldManager->addObject(object,true); //update watchers gContainerManager->createObjectToRegisteredPlayers(container, object); } // if (container->getObjectLoadCounter() == (container->getObjects())->size()) if(!ilc->mLoadCounter) { container->setLoadState(LoadState_Loaded); if (!(_removeFromObjectLoadMap(container->getId()))) LOG(WARNING) << "Failed removing object from loadmap"; ilc->mOfCallback->handleObjectReady(container,ilc->mClient); mILCPool.free(ilc); } }
void HouseFactory::handleObjectReady(Object* object,DispatchClient* client) { //Perform checking on startup there is no client! // client will in all cases be NULL in this factory //if(!client) // return; //add our cells InLoadingContainer* ilc = _getObject(object->getParentId()); //Perform checking. if(!ilc) { gLogger->log(LogManager::NOTICE,"House creation failed (HouseFactory.cpp line 289)"); return; } HouseObject* house = dynamic_cast<HouseObject*>(ilc->mObject); //add hopper / new item to worldObjectlist, but NOT to the SI gWorldManager->addObject(object,true); //pondering whether to use the objectcontainer instead house->addCell(dynamic_cast<CellObject*>(object)); if(house->getLoadCount() == (house->getCellList())->size()) { if(!(_removeFromObjectLoadMap(house->getId()))) gLogger->log(LogManager::NOTICE,"BuildingFactory: Failed removing object from loadmap"); ilc->mOfCallback->handleObjectReady(house,ilc->mClient); mILCPool.free(ilc); } }
void CellFactory::handleObjectReady(Object* object,DispatchClient* client) { InLoadingContainer* ilc = _getObject(object->getParentId()); if (! ilc) {//Crashbug fix: http://paste.swganh.org/viewp.php?id=20100627114151-8f7df7f74013af71c0d0b00bc240770d LOG(warning) << "Could not locate InLoadingContainer for object parent id [" << object->getParentId() << "]"; return; } CellObject* cell = dynamic_cast<CellObject*>(ilc->mObject); gWorldManager->addObject(object,true); switch(object->getType()) { case ObjType_NPC: case ObjType_Creature: { CreatureObject* creature = dynamic_cast<CreatureObject*>(object); if(creature->getCreoGroup() == CreoGroup_Shuttle) gWorldManager->addShuttle(dynamic_cast<Shuttle*>(creature)); } break; case ObjType_Tangible: { PlayerStructureTerminal* terminal = dynamic_cast<PlayerStructureTerminal*>(object); if(terminal) { terminal->setStructure(cell->getParentId()); } } break; case ObjType_Building: case ObjType_Cell: case ObjType_DraftSchematic: case ObjType_Structure: case ObjType_Intangible: case ObjType_Lair: case ObjType_Mission: case ObjType_None: case ObjType_NonPersistant: case ObjType_Player: case ObjType_Region: case ObjType_Waypoint: default: break; } auto permissions_objects_ = gObjectManager->GetPermissionsMap(); object->SetPermissions(permissions_objects_.find(swganh::object::DEFAULT_PERMISSION)->second.get());//CREATURE_PERMISSION gObjectManager->LoadSlotsForObject(object); cell->InitializeObject(object); cell->incLoad(); //LOG(info) << "cellFactory::handleObjectReady -> cell load stuff" << object->getId() << "for " << cell->getId(); //LOG(info) << "loadcount : " << cell->getLoadCount() << " : count : " << cell->getLoad(); if(cell->getLoadCount() == cell->getLoad()) { //LOG(info) << "cellFactory::handleObjectReady -> cell done " << cell->getId(); if(!(_removeFromObjectLoadMap(cell->getId()))) LOG(warning) << "Failed removing object from loadmap"; ilc->mOfCallback->handleObjectReady(cell,ilc->mClient); mILCPool.free(ilc); } }
void DatapadFactory::handleObjectReady(Object* object,DispatchClient* client) { Datapad* datapad(0); uint64 theID(0); switch(object->getType()) { case ObjType_Waypoint: { theID = object->getParentId()+3; mIlc = _getObject(theID); datapad = dynamic_cast<Datapad*>(mIlc->mObject); mIlc->mLoadCounter--; datapad->addWaypoint(dynamic_cast<WaypointObject*>(object)); } break; case ObjType_Tangible: { Item* item = dynamic_cast<Item*>(object); if(item->getItemType()== ItemType_ManSchematic) { theID = object->getParentId(); mIlc = _getObject(theID); if(!mIlc) { LOG(warning) << "Failed getting ilc during ObjType_Tangible where ItemType_ManSchematic"; return; } datapad = dynamic_cast<Datapad*>(mIlc->mObject); //parentId of schematics is the datapad! //add the msco to the datapad datapad->addManufacturingSchematic(dynamic_cast<ManufacturingSchematic*>(object)); //now load the associated item QueryContainerBase* asContainer = new(mQueryContainerPool.ordered_malloc()) QueryContainerBase(this,DPFQuery_ItemId,NULL); asContainer->mObject = datapad; asContainer->mId = item->getId();//queryContainer.mId; int8 sql[256]; sprintf(sql,"SELECT items.id FROM %s.items WHERE (parent_id=%" PRIu64 ")",mDatabase->galaxy(),item->getId()); mDatabase->executeSqlAsync(this,asContainer,sql); mObjectLoadMap.insert(std::make_pair(item->getId(),new(mILCPool.ordered_malloc()) InLoadingContainer(datapad,0,0,1))); } else { uint64 id = object->getParentId(); //we are loading the corresponding tangible object to have all the items attributes available for display/usage //find the corresponding schematic //temp mILc InLoadingContainer*mIlcDPad = _getObject(id); if(!mIlcDPad) { LOG(warning) << "Failed getting mIlcDPad during ObjType_Tangible"; return; } datapad = dynamic_cast<Datapad*>(mIlcDPad->mObject); _removeFromObjectLoadMap(id); mILCPool.free(mIlcDPad); //regular mIlc theID = datapad->getId(); mIlc = _getObject(theID); if(!mIlc) { LOG(warning) << "Failed getting ilc during ObjType_Tangible"; return; } ManufacturingSchematic* schem = datapad->getManufacturingSchematicById(id); //this is the item associated to the Man schematic //set the man schematic pointer and decrease the loadcount mIlc->mLoadCounter--; schem->setItem(dynamic_cast<Item*>(object)); } } break; case ObjType_Intangible: { theID = object->getParentId(); mIlc = _getObject(theID); if(!mIlc)//sanity { LOG(warning) << "Failed getting ilc during ObjType_Intangible"; return; } if((datapad = dynamic_cast<Datapad*>(mIlc->mObject))) { mIlc->mLoadCounter--; if(IntangibleObject* itno = dynamic_cast<IntangibleObject*>(object)) { if(datapad->getCapacity()) { datapad->addData(itno); Object* ob = gWorldManager->getObjectById(object->getId()); if(!ob) gWorldManager->addObject(object,true); } else { LOG(warning) << "Datapad at max Capacity"; delete(object); } } } } break; default: break; } if(!mIlc) return; if(!(mIlc->mLoadCounter)) { if(!(_removeFromObjectLoadMap(theID))) LOG(warning) << "Failed removing object from loadmap"; mIlc->mOfCallback->handleObjectReady(datapad,mIlc->mClient); mILCPool.free(mIlc); } }
void CellFactory::handleObjectReady(Object* object,DispatchClient* client) { InLoadingContainer* ilc = _getObject(object->getParentId()); if (! ilc) {//Crashbug fix: http://paste.swganh.org/viewp.php?id=20100627114151-8f7df7f74013af71c0d0b00bc240770d gLogger->log(LogManager::WARNING,"CellFactory::handleObjectReady could not locate ILC for objectParentId:%I64u",object->getParentId()); return; } CellObject* cell = dynamic_cast<CellObject*>(ilc->mObject); gWorldManager->addObject(object,true); switch(object->getType()) { case ObjType_NPC: case ObjType_Creature: { CreatureObject* creature = dynamic_cast<CreatureObject*>(object); if(creature->getCreoGroup() == CreoGroup_Shuttle) gWorldManager->addShuttle(dynamic_cast<Shuttle*>(creature)); } break; case ObjType_Tangible: { PlayerStructureTerminal* terminal = dynamic_cast<PlayerStructureTerminal*>(object); if(terminal) { terminal->setStructure(cell->getParentId()); } } break; case ObjType_Building: case ObjType_Cell: case ObjType_DraftSchematic: case ObjType_Structure: case ObjType_Intangible: case ObjType_Lair: case ObjType_Mission: case ObjType_None: case ObjType_NonPersistant: case ObjType_Player: case ObjType_Region: case ObjType_Waypoint: default: break; } cell->addObjectSecure(object); if(cell->getLoadCount() == cell->getObjects()->size()) { if(!(_removeFromObjectLoadMap(cell->getId()))) gLogger->log(LogManager::DEBUG,"CellFactory: Failed removing object from loadmap"); ilc->mOfCallback->handleObjectReady(cell,ilc->mClient); mILCPool.free(ilc); } }
void FactoryFactory::handleObjectReady(Object* object,DispatchClient* client) { //On serverstartup or factory create used to load in and out put hopper on factory create and to load hopper content //On runtime used to load hopper content when we access a hopper or to create a new factory //ILC ID on hoppercontent load is the hoppers ID InLoadingContainer* ilc = _getObject(object->getParentId()); if(!ilc) { //Crashbug patch for: http://paste.swganh.org/viewp.php?id=20100627071644-6c8c2b45ecb37f7914372484cd105bfe gLogger->log(LogManager::CRITICAL,"FactoryFactory::handleObjectReady: No ILC found for object parentId:%u", object->getParentId()); return; } FactoryObject* factory = dynamic_cast<FactoryObject*>(ilc->mObject); if(!factory) { factory = NULL; } //add hopper / new item to worldObjectlist, but NOT to the SI gWorldManager->addObject(object,true); //do we have a valid Object? TangibleObject* tangible = dynamic_cast<TangibleObject*>(object); if(!tangible) { gLogger->log(LogManager::DEBUG,"FactoryFactory: No Tangible on handleObjectReady!!!!!!!!!!!!!!!!"); return; } uint64 parent = 0; if(strcmp(tangible->getName().getAnsi(),"ingredient_hopper")==0) { factory->setIngredientHopper(object->getId()); factory->addObject(object); } else if(strcmp(tangible->getName().getAnsi(),"output_hopper")==0) { factory->setOutputHopper(object->getId()); factory->addObject(object); } else { //its a tangible item of a hopper read in during runtime TangibleObject* hopper; if(factory->getOutputHopper() == tangible->getParentId()) { hopper = dynamic_cast<TangibleObject*>(gWorldManager->getObjectById(factory->getOutputHopper())); } else { hopper = dynamic_cast<TangibleObject*>(gWorldManager->getObjectById(factory->getIngredientHopper())); } if(!hopper) { gLogger->log(LogManager::CRITICAL,"FactoryFactory: outputHopper not found on item load !!!!!!!"); assert(false && "FactoryFactory::handleObjectReady WorldManager could not find output hopper"); } parent = hopper->getId(); //add to hopper / create for players hopper->handleObjectReady(object,NULL); } if(( --ilc->mLoadCounter) == 0) { if(!(_removeFromObjectLoadMap(object->getParentId()))) gLogger->log(LogManager::DEBUG,"FactoryFactory: Failed removing object from loadmap"); factory->setLoadState(LoadState_Loaded); if(!parent) //factories dont have a parent! main cell is 0!!! ilc->mOfCallback->handleObjectReady(factory,ilc->mClient); else ilc->mOfCallback->handleObjectReady(factory,ilc->mClient,parent); //only hoppers have a parent (the factory) mILCPool.free(ilc); } }
void FactoryFactory::handleDatabaseJobComplete(void* ref,DatabaseResult* result) { QueryContainerBase* asyncContainer = reinterpret_cast<QueryContainerBase*>(ref); switch(asyncContainer->mQueryType) { case FFQuery_HopperItemAttributeUpdate: { Type1_QueryContainer queryContainer; DataBinding* binding = mDatabase->CreateDataBinding(1); binding->addField(DFT_bstring,offsetof(Type1_QueryContainer,mString),64,0); uint64 count; count = result->getRowCount(); // should be 1 result featuring the value as string // note that we can get MySQL to give us the resContainersVolume as string as we just tell it to not cast the value // MySQL just uses strings in its interface!! so we just wait and cast the value in the virtual function // this way we dont have to differentiate between resourceContainers and FactoryCrates and save ourselves alot of unecessary work for(uint64 i = 0; i < count; i++) { TangibleObject* tangible = dynamic_cast<TangibleObject*>(gWorldManager->getObjectById(asyncContainer->mId)); if(!tangible) { gLogger->log(LogManager::DEBUG,"FactoryFactory::FFQuery_HopperItemAttributeUpdate No tangible"); mDatabase->DestroyDataBinding(binding); return; } result->GetNextRow(binding,&queryContainer); tangible->upDateFactoryVolume(queryContainer.mString); //virtual function present in tangible, resourceContainer and factoryCrate } InLoadingContainer* ilc = _getObject(asyncContainer->mHopper); if(!ilc) { //Crashbug patch for: http://paste.swganh.org/viewp.php?id=20100627075436-83ca0076fa8abc2a4347e45ee3ede3eb mDatabase->DestroyDataBinding(binding); gLogger->log(LogManager::CRITICAL,"FactoryFactory::handleObjectReady: No ILC found for asyncContainer->mHopper:%u", asyncContainer->mId); return; } if((--ilc->mLoadCounter)== 0) { gLogger->log(LogManager::DEBUG,"FactoryFactory: FFQuery_HopperItemAttributeUpdate attribute load ended item refresh!"); if(!(_removeFromObjectLoadMap(asyncContainer->mHopper))) gLogger->log(LogManager::DEBUG,"FactoryFactory: Failed removing object from loadmap"); ilc->mOfCallback->handleObjectReady(asyncContainer->mObject,ilc->mClient,asyncContainer->mHopper); mILCPool.free(ilc); } mDatabase->DestroyDataBinding(binding); } break; case FFQuery_HopperUpdate: { //the player openened a factories hopper. //we now asynchronically read the hopper and its content and update them when necessary Type1_QueryContainer queryContainer; DataBinding* binding = mDatabase->CreateDataBinding(2); binding->addField(DFT_bstring,offsetof(Type1_QueryContainer,mString),64,0); binding->addField(DFT_uint64,offsetof(Type1_QueryContainer,mId),8,1); uint64 count; count = result->getRowCount(); if(!count) { asyncContainer->mOfCallback->handleObjectReady(asyncContainer->mObject,asyncContainer->mClient,asyncContainer->mHopper); mDatabase->DestroyDataBinding(binding); return; } //asyncContainer->mId == HOPPER!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!1 mObjectLoadMap.insert(std::make_pair(asyncContainer->mId,new(mILCPool.ordered_malloc()) InLoadingContainer(asyncContainer->mObject,asyncContainer->mOfCallback,asyncContainer->mClient,(uint32)count))); for(uint64 i = 0; i < count; i++) { result->GetNextRow(binding,&queryContainer); //read in the ID - find the item in the world or load it newly if(strcmp(queryContainer.mString.getAnsi(),"item") == 0) { Item* item = dynamic_cast<Item*>(gWorldManager->getObjectById(queryContainer.mId)); if(!item) { //the item is new - load it over the itemfactory gTangibleFactory->requestObject(this,queryContainer.mId,TanGroup_Item,0,asyncContainer->mClient); } //else update relevant attributes else { QueryContainerBase* asynContainer = new(mQueryContainerPool.ordered_malloc()) QueryContainerBase(asyncContainer->mOfCallback,FFQuery_HopperItemAttributeUpdate,asyncContainer->mClient,queryContainer.mId); asynContainer->mObject = asyncContainer->mObject; asynContainer->mHopper = asyncContainer->mHopper; mDatabase->ExecuteSqlAsync(this,asynContainer, "SELECT value FROM item_attributes WHERE item_id = %"PRIu64" AND attribute_id = 400", queryContainer.mId); } } if(strcmp(queryContainer.mString.getAnsi(),"resource") == 0) { ResourceContainer* rc = dynamic_cast<ResourceContainer*>(gWorldManager->getObjectById(queryContainer.mId)); if(!rc) { //the container is new - load it over the itemfactory gTangibleFactory->requestObject(this,queryContainer.mId,TanGroup_ResourceContainer,0,asyncContainer->mClient); } else { QueryContainerBase* asynContainer = new(mQueryContainerPool.ordered_malloc()) QueryContainerBase(asyncContainer->mOfCallback,FFQuery_HopperItemAttributeUpdate,asyncContainer->mClient,queryContainer.mId); asynContainer->mObject = asyncContainer->mObject; asynContainer->mHopper = asyncContainer->mHopper; mDatabase->ExecuteSqlAsync(this,asynContainer, "SELECT amount FROM resource_containers WHERE id= %"PRIu64"", queryContainer.mId); } } } mDatabase->DestroyDataBinding(binding); } break; case FFQuery_AttributeData: { FactoryObject* factory = dynamic_cast<FactoryObject*>(asyncContainer->mObject); //_buildAttributeMap(harvester,result); Attribute_QueryContainer attribute; uint64 count = result->getRowCount(); //int8 str[256]; //BStringVector dataElements; for(uint64 i = 0; i < count; i++) { result->GetNextRow(mAttributeBinding,(void*)&attribute); factory->addInternalAttribute(attribute.mKey,std::string(attribute.mValue.getAnsi())); } QueryContainerBase* asContainer = new(mQueryContainerPool.ordered_malloc()) QueryContainerBase(asyncContainer->mOfCallback,FFQuery_Hopper,asyncContainer->mClient); asContainer->mObject = factory; mDatabase->ExecuteSqlAsync(this,asContainer, "(SELECT \'input\',id FROM items WHERE parent_id = %"PRIu64" AND item_type = 2773) UNION (SELECT \'output\',id FROM items WHERE parent_id = %"PRIu64" AND item_type = 2774)", factory->getId(), factory->getId()); gLogger->log(LogManager::DEBUG, "(SELECT \'input\',id FROM items WHERE parent_id = %"PRIu64" AND item_type = 2773) UNION (SELECT \'output\',id FROM items WHERE parent_id = %"PRIu64" AND item_type = 2774)", factory->getId(), factory->getId()); // SQL Debug Log } break; case FFQuery_Hopper: { FactoryObject* factory = dynamic_cast<FactoryObject*>(asyncContainer->mObject); Type1_QueryContainer queryContainer; DataBinding* binding = mDatabase->CreateDataBinding(2); binding->addField(DFT_bstring,offsetof(Type1_QueryContainer,mString),64,0); binding->addField(DFT_uint64,offsetof(Type1_QueryContainer,mId),8,1); uint64 count = result->getRowCount(); //InLoadingContainer* ilc = new(mILCPool.ordered_malloc()) InLoadingContainer(inventory,asyncContainer->mOfCallback,asyncContainer->mClient); //ilc->mLoadCounter = count; //mObjectLoadMap.insert(std::make_pair(datapad->getId(),new(mILCPool.ordered_malloc()) InLoadingContainer(datapad,asyncContainer->mOfCallback,asyncContainer->mClient,static_cast<uint32>(count)))); mObjectLoadMap.insert(std::make_pair(factory->getId(),new(mILCPool.ordered_malloc()) InLoadingContainer(factory,asyncContainer->mOfCallback,asyncContainer->mClient,2))); for(uint32 i = 0; i < count; i++) { result->GetNextRow(binding,&queryContainer); if(strcmp(queryContainer.mString.getAnsi(),"input") == 0) { gTangibleFactory->requestObject(this,queryContainer.mId,TanGroup_Hopper,0,NULL); } else if(strcmp(queryContainer.mString.getAnsi(),"output") == 0) { gTangibleFactory->requestObject(this,queryContainer.mId,TanGroup_Hopper,0,NULL); } } mDatabase->DestroyDataBinding(binding); } break; case FFQuery_MainData: { QueryContainerBase* asynContainer = new(mQueryContainerPool.ordered_malloc()) QueryContainerBase(asyncContainer->mOfCallback,FFQuery_AttributeData,asyncContainer->mClient,asyncContainer->mId); FactoryObject* factory = new(FactoryObject); _createFactory(result,factory); asynContainer->mObject = factory; asynContainer->mClient = asyncContainer->mClient; asynContainer->mId = factory->getId(); mDatabase->ExecuteSqlAsync(this,asynContainer,"SELECT attributes.name,sa.value,attributes.internal" " FROM structure_attributes sa" " INNER JOIN attributes ON (sa.attribute_id = attributes.id)" " WHERE sa.structure_id = %"PRIu64" ORDER BY sa.order",factory->getId()); } break; default: break; } mQueryContainerPool.free(asyncContainer); }