Chameleon

Chameleon Commit Details

Date:2011-07-05 09:00:49 (8 years 3 months ago)
Author:Evan Lojewski
Commit:1112
Parents: 1111
Message:Updated xml parser.
Changes:
M/trunk/i386/libsaio/xml.h
M/trunk/i386/libsaio/xml.c

File differences

trunk/i386/libsaio/xml.c
10971097
10981098
10991099
1100
1101
1102
1103
1104
11001105
11011106
11021107
......
11041109
11051110
11061111
1112
1113
1114
1115
1116
1117
11071118
11081119
11091120
......
11111122
11121123
11131124
1125
1126
1127
1128
1129
1130
1131
11141132
11151133
11161134
......
11351153
11361154
11371155
1156
1157
1158
1159
1160
1161
1162
11381163
11391164
11401165
......
11421167
11431168
11441169
1170
1171
1172
1173
1174
11451175
11461176
11471177
}
/*** Cast functions ***/
bool XMLIsArray(TagPtr entry)
{
return entry && (entry->type == kTagTypeArray);
}
TagPtr XMLCastArray(TagPtr dict)
{
if(!dict) return NULL;
else return NULL;
}
bool XMLIsDict(TagPtr entry)
{
return entry && (entry->type == kTagTypeDict);
}
TagPtr XMLCastDict(TagPtr dict)
{
if(!dict) return NULL;
else return NULL;
}
bool XMLIsString(TagPtr entry)
{
return entry &&
((dict->type == kTagTypeString) ||
(dict->type == kTagTypeKey));
}
char* XMLCastString(TagPtr dict)
{
if(!dict) return NULL;
}
}
bool XMLIsBoolean(TagPtr entry)
{
return entry &&
((entry->type == kTagTypeTrue) ||
(entry->type == kTagTypeFalse));
}
bool XMLCastBoolean(TagPtr dict)
{
if(!dict) return false;
return false;
}
bool XMLIsInteger(TagPtr entry)
{
return entry && (entry->type == kTagTypeInteger);
}
int XMLCastInteger(TagPtr dict)
{
if(!dict)
trunk/i386/libsaio/xml.h
9898
9999
100100
101
102
103
104
105
106
107
101108
102109
103110
TagPtr XMLCastDict ( TagPtr dict );
TagPtr XMLCastArray( TagPtr dict );
bool XMLIsBoolean(TagPtr entry);
bool XMLIsString (TagPtr entry);
bool XMLIsInteger(TagPtr entry);
bool XMLIsDict (TagPtr entry);
bool XMLIsArray (TagPtr entry);
bool XMLAddTagToDictionary(TagPtr dict, char* key, TagPtr value);
long XMLParseNextTag(char *buffer, TagPtr *tag);

Archive Download the corresponding diff file

Revision: 1112