----------------------------------------------------- //
| 989 | |
| 990 | // ----------------------------------------------------- // |
| 991 | char *bFile::getFileElement(short *firstStruct, char *lookupName, char *lookupType, char *data, short **foundPos) |
| 992 | { |
| 993 | short *old = firstStruct; //mFileDNA->getStruct(old_nr); |
| 994 | int elementLength = old[1]; |
| 995 | old += 2; |
| 996 | |
| 997 | for (int i = 0; i < elementLength; i++, old += 2) |
| 998 | { |
| 999 | char *type = mFileDNA->getType(old[0]); |
| 1000 | char *name = mFileDNA->getName(old[1]); |
| 1001 | int len = mFileDNA->getElementSize(old[0], old[1]); |
| 1002 | |
| 1003 | if (strcmp(lookupName, name) == 0) |
| 1004 | { |
| 1005 | if (strcmp(type, lookupType) == 0) |
| 1006 | { |
| 1007 | if (foundPos) |
| 1008 | *foundPos = old; |
| 1009 | return data; |
| 1010 | } |
| 1011 | return 0; |
| 1012 | } |
| 1013 | data += len; |
| 1014 | } |
| 1015 | return 0; |
| 1016 | } |
| 1017 | |
| 1018 | // ----------------------------------------------------- // |
| 1019 | void bFile::swapStruct(int dna_nr, char *data, bool ignoreEndianFlag) |
nothing calls this directly
no test coverage detected