Created
December 28, 2010 19:58
-
-
Save emad-elsaid/757626 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
the getobject algorithm steps : | |
input: uuid, entityName, offset | |
1- get file number from uuid file assume the file number to variable [FILE] | |
2- get from database the [ENTITYID] corresponding to entityname | |
3- now query lines IDs from database table ifc where table id [FILE] and entityname [ENTITYID] | |
4- now check the first ID from ID where ID is not in file uuid | |
5- get object with line id=ID and file=[FILE], | |
6- get related objects [RELIDs] from the references table | |
7- get get related object to related object ...(recursive algorithm) to get the full object tree. | |
8- Now we have all needed IDs in FULLIDs array | |
9- query IFC table to get the lines required where ID in FULLIDs and file = FILE | |
10- now convert all records to step syntax by #lineID = entityname(recordfile) | |
11- concatenate all lines to OUTPUT | |
12- return the sub string from OUTPUT by offset and length=WCF limit |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment