mirror of
https://github.com/gnustep/libs-base.git
synced 2025-05-11 16:50:42 +00:00
Add deprecation support
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@21209 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
a5cf839255
commit
80152a8a0d
6 changed files with 122 additions and 95 deletions
|
@ -1,3 +1,11 @@
|
|||
2005-05-10 Richard Frith-Macdonald <rfm@gnu.org>
|
||||
|
||||
* Tools/AGSHtml.h:
|
||||
* Tools/AGSHtml.m:
|
||||
* Tools/AGSParser.m:
|
||||
* Tools/gsdoc-1_0_2.dtd:
|
||||
Support deprecation version as well as addition/removal.
|
||||
|
||||
2005-05-09 David Ayers <d.ayers@inode.at>
|
||||
|
||||
* Source/NSPropertyList.m (OAppend): Revert patch from
|
||||
|
|
|
@ -26,6 +26,7 @@
|
|||
|
||||
@interface AGSHtml : NSObject
|
||||
{
|
||||
NSString *project;
|
||||
AGSIndex *localRefs;
|
||||
AGSIndex *globalRefs;
|
||||
AGSIndex *projectRefs;
|
||||
|
|
|
@ -84,6 +84,7 @@ static NSString *mainFont = nil;
|
|||
|
||||
- (void) dealloc
|
||||
{
|
||||
RELEASE(project);
|
||||
RELEASE(globalRefs);
|
||||
RELEASE(localRefs);
|
||||
RELEASE(projectRefs);
|
||||
|
@ -109,6 +110,8 @@ static NSString *mainFont = nil;
|
|||
- (id) init
|
||||
{
|
||||
indent = [[NSMutableString alloc] initWithCapacity: 64];
|
||||
project = RETAIN([[NSUserDefaults standardUserDefaults]
|
||||
stringForKey: @"Project"]);
|
||||
return self;
|
||||
}
|
||||
|
||||
|
@ -2346,52 +2349,72 @@ static NSString *mainFont = nil;
|
|||
{
|
||||
NSString *ovadd = [prop objectForKey: @"ovadd"];
|
||||
NSString *gvadd = [prop objectForKey: @"gvadd"];
|
||||
NSString *ovdep = [prop objectForKey: @"ovdep"];
|
||||
NSString *gvdep = [prop objectForKey: @"gvdep"];
|
||||
NSString *ovrem = [prop objectForKey: @"ovrem"];
|
||||
NSString *gvrem = [prop objectForKey: @"gvrem"];
|
||||
|
||||
if ([ovadd length] > 0)
|
||||
{
|
||||
int add = [ovadd intValue];
|
||||
int dep = [ovdep intValue];
|
||||
int rem = [ovrem intValue];
|
||||
|
||||
[buf appendString: indent];
|
||||
[buf appendString: @"<b>Releases:</b>"];
|
||||
[buf appendString: @"<b>Releases:</b> "];
|
||||
if (add < 4)
|
||||
{
|
||||
[buf appendString: @" OpenStep"];
|
||||
[buf appendString: @"OpenStep"];
|
||||
}
|
||||
else if (add < 10)
|
||||
{
|
||||
[buf appendString: @" OPENSTEP "];
|
||||
[buf appendString: @"OPENSTEP"];
|
||||
[buf appendString: ovadd];
|
||||
}
|
||||
else
|
||||
{
|
||||
[buf appendString: @" MacOS-X "];
|
||||
[buf appendString: @"MacOS-X"];
|
||||
[buf appendString: ovadd];
|
||||
}
|
||||
if (dep > add)
|
||||
{
|
||||
[buf appendString: @" deprecated at "];
|
||||
if (add < 10)
|
||||
{
|
||||
[buf appendString: @"OPENSTEP"];
|
||||
[buf appendString: ovdep];
|
||||
}
|
||||
else
|
||||
{
|
||||
[buf appendString: @"MacOS-X"];
|
||||
[buf appendString: ovdep];
|
||||
}
|
||||
}
|
||||
if (rem > add)
|
||||
{
|
||||
[buf appendString: @" removed at "];
|
||||
if (add < 4)
|
||||
if (add < 10)
|
||||
{
|
||||
[buf appendString: @" OpenStep"];
|
||||
}
|
||||
else if (add < 10)
|
||||
{
|
||||
[buf appendString: @" OPENSTEP "];
|
||||
[buf appendString: ovadd];
|
||||
[buf appendString: @"OPENSTEP"];
|
||||
[buf appendString: ovrem];
|
||||
}
|
||||
else
|
||||
{
|
||||
[buf appendString: @" MacOS-X "];
|
||||
[buf appendString: ovadd];
|
||||
[buf appendString: @"MacOS-X"];
|
||||
[buf appendString: ovrem];
|
||||
}
|
||||
}
|
||||
if ([gvadd length] > 0)
|
||||
{
|
||||
[buf appendString: @", GNUstep "];
|
||||
[buf appendString: @", "];
|
||||
[buf appendString: project];
|
||||
[buf appendString: @" "];
|
||||
[buf appendString: gvadd];
|
||||
if ([gvdep length] > 0)
|
||||
{
|
||||
[buf appendString: @" deprecated at "];
|
||||
[buf appendString: gvdep];
|
||||
}
|
||||
if ([gvrem length] > 0)
|
||||
{
|
||||
[buf appendString: @" removed at "];
|
||||
|
@ -2403,9 +2426,16 @@ static NSString *mainFont = nil;
|
|||
else if ([gvadd length] > 0)
|
||||
{
|
||||
[buf appendString: indent];
|
||||
[buf appendString: @"<b>Releases:</b>"];
|
||||
[buf appendString: @"GNUstep "];
|
||||
[buf appendString: @"<b>Releases:</b> "];
|
||||
[buf appendString: project];
|
||||
[buf appendString: @" "];
|
||||
[buf appendString: gvadd];
|
||||
if ([gvdep length] > 0)
|
||||
{
|
||||
[buf appendString: @" deprecated at "];
|
||||
[buf appendString: gvdep];
|
||||
}
|
||||
[buf appendString: @"<br />\n"];
|
||||
if ([gvrem length] > 0)
|
||||
{
|
||||
[buf appendString: @" removed at "];
|
||||
|
|
|
@ -2946,6 +2946,9 @@ fail:
|
|||
return [self skipRemainderOfLine];
|
||||
}
|
||||
hadOstep = YES;
|
||||
[top removeObjectForKey: @"ovadd"];
|
||||
[top removeObjectForKey: @"ovdep"];
|
||||
[top removeObjectForKey: @"ovrem"];
|
||||
}
|
||||
else if ([arg isEqual: @"GS_API_VERSION"] == YES)
|
||||
{
|
||||
|
@ -2956,17 +2959,16 @@ fail:
|
|||
return [self skipRemainderOfLine];
|
||||
}
|
||||
hadGstep = YES;
|
||||
[top removeObjectForKey: @"gvadd"];
|
||||
[top removeObjectForKey: @"gvdep"];
|
||||
[top removeObjectForKey: @"gvrem"];
|
||||
}
|
||||
else
|
||||
{
|
||||
break;
|
||||
}
|
||||
|
||||
while (pos < length
|
||||
&& [spaces characterIsMember: buffer[pos]] == YES)
|
||||
{
|
||||
pos++;
|
||||
}
|
||||
[self parseSpace: spaces];
|
||||
if (pos < length && buffer[pos] == '(')
|
||||
{
|
||||
pos++;
|
||||
|
@ -2987,11 +2989,7 @@ fail:
|
|||
[top setObject: ver forKey: @"gvadd"];
|
||||
}
|
||||
|
||||
while (pos < length
|
||||
&& [spaces characterIsMember: buffer[pos]] == YES)
|
||||
{
|
||||
pos++;
|
||||
}
|
||||
[self parseSpace: spaces];
|
||||
if (pos < length && buffer[pos] == ',')
|
||||
{
|
||||
pos++;
|
||||
|
@ -3002,18 +3000,7 @@ fail:
|
|||
ver = @"9999";
|
||||
}
|
||||
i = [ver intValue];
|
||||
if (i == 9999 || [ver isEqualToString: @"NEVER"] == YES)
|
||||
{
|
||||
if (openstep)
|
||||
{
|
||||
[top removeObjectForKey: @"ovrem"];
|
||||
}
|
||||
else
|
||||
{
|
||||
[top removeObjectForKey: @"gvrem"];
|
||||
}
|
||||
}
|
||||
else
|
||||
if (i != 9999 && [ver isEqualToString: @"NEVER"] == NO)
|
||||
{
|
||||
ver = [NSString stringWithFormat: @"%d.%d", i/100, i%100];
|
||||
if (openstep)
|
||||
|
@ -3026,21 +3013,37 @@ fail:
|
|||
}
|
||||
}
|
||||
|
||||
while (pos < length
|
||||
&& [spaces characterIsMember: buffer[pos]] == YES)
|
||||
[self parseSpace: spaces];
|
||||
if (pos < length && buffer[pos] == ',')
|
||||
{
|
||||
pos++;
|
||||
ver = [self parseVersion];
|
||||
if ([ver length] == 0)
|
||||
{
|
||||
ver = @"9999";
|
||||
}
|
||||
i = [ver intValue];
|
||||
if (i != 9999 && [ver isEqualToString: @"NEVER"] == NO)
|
||||
{
|
||||
ver = [NSString stringWithFormat: @"%d.%d", i/100, i%100];
|
||||
if (openstep)
|
||||
{
|
||||
[top setObject: ver forKey: @"ovdep"];
|
||||
}
|
||||
else
|
||||
{
|
||||
[top setObject: ver forKey: @"gvdep"];
|
||||
}
|
||||
}
|
||||
[self parseSpace: spaces];
|
||||
}
|
||||
|
||||
if (pos < length && buffer[pos] == ')')
|
||||
{
|
||||
pos++;
|
||||
}
|
||||
|
||||
while (pos < length
|
||||
&& [spaces characterIsMember: buffer[pos]] == YES)
|
||||
{
|
||||
pos++;
|
||||
}
|
||||
[self parseSpace: spaces];
|
||||
if (pos < length-1 && buffer[pos] == '&' && buffer[pos+1] == '&')
|
||||
{
|
||||
pos += 2;
|
||||
|
@ -3058,11 +3061,7 @@ fail:
|
|||
{
|
||||
BOOL isIfDef = [directive isEqual: @"ifdef"];
|
||||
|
||||
while (pos < length
|
||||
&& [spaces characterIsMember: buffer[pos]] == YES)
|
||||
{
|
||||
pos++;
|
||||
}
|
||||
[self parseSpace: spaces];
|
||||
if (pos < length && buffer[pos] != '\n')
|
||||
{
|
||||
NSMutableDictionary *top;
|
||||
|
@ -3462,6 +3461,10 @@ fail:
|
|||
if (ovadd != nil)
|
||||
{
|
||||
[m appendFormat: @" ovadd=\"%@\"", ovadd];
|
||||
if ((s = [top objectForKey: @"ovdep"]) != nil)
|
||||
{
|
||||
[m appendFormat: @" ovdep=\"%@\"", s];
|
||||
}
|
||||
if ((s = [top objectForKey: @"ovrem"]) != nil)
|
||||
{
|
||||
[m appendFormat: @" ovrem=\"%@\"", s];
|
||||
|
@ -3470,6 +3473,10 @@ fail:
|
|||
if (gvadd != nil)
|
||||
{
|
||||
[m appendFormat: @" gvadd=\"%@\"", gvadd];
|
||||
if ((s = [top objectForKey: @"gvdep"]) != nil)
|
||||
{
|
||||
[m appendFormat: @" gvdep=\"%@\"", s];
|
||||
}
|
||||
if ((s = [top objectForKey: @"gvrem"]) != nil)
|
||||
{
|
||||
[m appendFormat: @" gvrem=\"%@\"", s];
|
||||
|
|
|
@ -240,11 +240,6 @@
|
|||
is used to override some information from the same method in the
|
||||
superclass.
|
||||
If factory not set, instance method
|
||||
|
||||
gvadd is the gnustep version at which this was introduced
|
||||
gvrem is the gnustep version at which this was removed
|
||||
ovadd is the OpenStep/OPENSTEP/MacOS-X version at which this was introduced
|
||||
ovrem is the OpenStep/OPENSTEP/MacOS-X version at which this was removed
|
||||
-->
|
||||
<!ELEMENT method (((sel, arg?), (sel, arg)*, vararg?), desc?, standards?)>
|
||||
<!ATTLIST method
|
||||
|
@ -253,8 +248,10 @@
|
|||
init %boolean; "no"
|
||||
override (subclass|never) #IMPLIED
|
||||
gvadd CDATA #IMPLIED
|
||||
gvdep CDATA #IMPLIED
|
||||
gvrem CDATA #IMPLIED
|
||||
ovadd CDATA #IMPLIED
|
||||
ovdep CDATA #IMPLIED
|
||||
ovrem CDATA #IMPLIED
|
||||
>
|
||||
|
||||
|
@ -264,42 +261,34 @@
|
|||
<!ELEMENT declared (#PCDATA)*>
|
||||
|
||||
<!-- A macro definition.
|
||||
gvadd is the gnustep version at which this was introduced
|
||||
gvrem is the gnustep version at which this was removed
|
||||
ovadd is the OpenStep/OPENSTEP/MacOS-X version at which this was introduced
|
||||
ovrem is the OpenStep/OPENSTEP/MacOS-X version at which this was removed
|
||||
-->
|
||||
<!ELEMENT macro ((arg*, vararg?), declared?, desc?, standards?)>
|
||||
<!ATTLIST macro
|
||||
name CDATA #REQUIRED
|
||||
gvadd CDATA #IMPLIED
|
||||
gvdep CDATA #IMPLIED
|
||||
gvrem CDATA #IMPLIED
|
||||
ovadd CDATA #IMPLIED
|
||||
ovdep CDATA #IMPLIED
|
||||
ovrem CDATA #IMPLIED
|
||||
>
|
||||
|
||||
<!-- A type definition.
|
||||
gvadd is the gnustep version at which this was introduced
|
||||
gvrem is the gnustep version at which this was removed
|
||||
ovadd is the OpenStep/OPENSTEP/MacOS-X version at which this was introduced
|
||||
ovrem is the OpenStep/OPENSTEP/MacOS-X version at which this was removed
|
||||
-->
|
||||
<!ELEMENT type (declared?, desc?, standards?)>
|
||||
<!ATTLIST type
|
||||
name CDATA #REQUIRED
|
||||
type CDATA #REQUIRED
|
||||
gvadd CDATA #IMPLIED
|
||||
gvdep CDATA #IMPLIED
|
||||
gvrem CDATA #IMPLIED
|
||||
ovadd CDATA #IMPLIED
|
||||
ovdep CDATA #IMPLIED
|
||||
ovrem CDATA #IMPLIED
|
||||
>
|
||||
|
||||
<!-- Variable definition.
|
||||
VALUE may be set for a constant or a default value
|
||||
gvadd is the gnustep version at which this was introduced
|
||||
gvrem is the gnustep version at which this was removed
|
||||
ovadd is the OpenStep/OPENSTEP/MacOS-X version at which this was introduced
|
||||
ovrem is the OpenStep/OPENSTEP/MacOS-X version at which this was removed
|
||||
-->
|
||||
<!ELEMENT variable (declared?, desc?, standards?)>
|
||||
<!ATTLIST variable
|
||||
|
@ -307,16 +296,14 @@
|
|||
type CDATA #REQUIRED
|
||||
value CDATA #IMPLIED
|
||||
gvadd CDATA #IMPLIED
|
||||
gvdep CDATA #IMPLIED
|
||||
gvrem CDATA #IMPLIED
|
||||
ovadd CDATA #IMPLIED
|
||||
ovdep CDATA #IMPLIED
|
||||
ovrem CDATA #IMPLIED
|
||||
>
|
||||
|
||||
<!-- Ivariable definition.
|
||||
gvadd is the gnustep version at which this was introduced
|
||||
gvrem is the gnustep version at which this was removed
|
||||
ovadd is the OpenStep/OPENSTEP/MacOS-X version at which this was introduced
|
||||
ovrem is the OpenStep/OPENSTEP/MacOS-X version at which this was removed
|
||||
-->
|
||||
<!ELEMENT ivariable (desc?, standards?)>
|
||||
<!ATTLIST ivariable
|
||||
|
@ -324,17 +311,15 @@
|
|||
type CDATA #REQUIRED
|
||||
validity (public|protected|private) "public"
|
||||
gvadd CDATA #IMPLIED
|
||||
gvdep CDATA #IMPLIED
|
||||
gvrem CDATA #IMPLIED
|
||||
ovadd CDATA #IMPLIED
|
||||
ovdep CDATA #IMPLIED
|
||||
ovrem CDATA #IMPLIED
|
||||
>
|
||||
|
||||
<!-- Constant definition.
|
||||
VALUE may be set for a constant or a default value
|
||||
gvadd is the gnustep version at which this was introduced
|
||||
gvrem is the gnustep version at which this was removed
|
||||
ovadd is the OpenStep/OPENSTEP/MacOS-X version at which this was introduced
|
||||
ovrem is the OpenStep/OPENSTEP/MacOS-X version at which this was removed
|
||||
-->
|
||||
<!ELEMENT constant (declared?, desc?, standards?)>
|
||||
<!ATTLIST constant
|
||||
|
@ -343,63 +328,55 @@
|
|||
value CDATA #IMPLIED
|
||||
role (except|defaults|notify|key) #IMPLIED
|
||||
gvadd CDATA #IMPLIED
|
||||
gvdep CDATA #IMPLIED
|
||||
gvrem CDATA #IMPLIED
|
||||
ovadd CDATA #IMPLIED
|
||||
ovdep CDATA #IMPLIED
|
||||
ovrem CDATA #IMPLIED
|
||||
>
|
||||
|
||||
<!-- A function definition.
|
||||
gvadd is the gnustep version at which this was introduced
|
||||
gvrem is the gnustep version at which this was removed
|
||||
ovadd is the OpenStep/OPENSTEP/MacOS-X version at which this was introduced
|
||||
ovrem is the OpenStep/OPENSTEP/MacOS-X version at which this was removed
|
||||
-->
|
||||
<!ELEMENT function ((arg*, vararg?), declared?, desc?, standards?)>
|
||||
<!ATTLIST function
|
||||
name CDATA #REQUIRED
|
||||
type CDATA #REQUIRED
|
||||
gvadd CDATA #IMPLIED
|
||||
gvdep CDATA #IMPLIED
|
||||
gvrem CDATA #IMPLIED
|
||||
ovadd CDATA #IMPLIED
|
||||
ovdep CDATA #IMPLIED
|
||||
ovrem CDATA #IMPLIED
|
||||
>
|
||||
|
||||
<!-- Protocol definition.
|
||||
gvadd is the gnustep version at which this was introduced
|
||||
gvrem is the gnustep version at which this was removed
|
||||
ovadd is the OpenStep/OPENSTEP/MacOS-X version at which this was introduced
|
||||
ovrem is the OpenStep/OPENSTEP/MacOS-X version at which this was removed
|
||||
-->
|
||||
<!ELEMENT protocol (declared?, conform*, desc?, method*, standards?)>
|
||||
<!ATTLIST protocol
|
||||
name CDATA #REQUIRED
|
||||
gvadd CDATA #IMPLIED
|
||||
gvdep CDATA #IMPLIED
|
||||
gvrem CDATA #IMPLIED
|
||||
ovadd CDATA #IMPLIED
|
||||
ovdep CDATA #IMPLIED
|
||||
ovrem CDATA #IMPLIED
|
||||
>
|
||||
|
||||
<!-- Category definition.
|
||||
gvadd is the gnustep version at which this was introduced
|
||||
gvrem is the gnustep version at which this was removed
|
||||
ovadd is the OpenStep/OPENSTEP/MacOS-X version at which this was introduced
|
||||
ovrem is the OpenStep/OPENSTEP/MacOS-X version at which this was removed
|
||||
-->
|
||||
<!ELEMENT category (declared?, conform*, desc?, method*, standards?)>
|
||||
<!ATTLIST category
|
||||
name CDATA #REQUIRED
|
||||
class CDATA #REQUIRED
|
||||
gvadd CDATA #IMPLIED
|
||||
gvdep CDATA #IMPLIED
|
||||
gvrem CDATA #IMPLIED
|
||||
ovadd CDATA #IMPLIED
|
||||
ovdep CDATA #IMPLIED
|
||||
ovrem CDATA #IMPLIED
|
||||
>
|
||||
|
||||
<!-- Show a protocol a class conforms to.
|
||||
gvadd is the gnustep version at which this was introduced
|
||||
gvrem is the gnustep version at which this was removed
|
||||
ovadd is the OpenStep/OPENSTEP/MacOS-X version at which this was introduced
|
||||
ovrem is the OpenStep/OPENSTEP/MacOS-X version at which this was removed
|
||||
-->
|
||||
<!ELEMENT conform (#PCDATA)*>
|
||||
|
||||
|
@ -408,8 +385,10 @@
|
|||
name CDATA #REQUIRED
|
||||
super CDATA #IMPLIED
|
||||
gvadd CDATA #IMPLIED
|
||||
gvdep CDATA #IMPLIED
|
||||
gvrem CDATA #IMPLIED
|
||||
ovadd CDATA #IMPLIED
|
||||
ovdep CDATA #IMPLIED
|
||||
ovrem CDATA #IMPLIED
|
||||
>
|
||||
|
||||
|
|
|
@ -610,11 +610,13 @@
|
|||
not need to write GSDoc using these elements, since they can be
|
||||
autogenerated from Objective-C source files and special comments
|
||||
within them. Most of the elements representing parts of the API
|
||||
have optional attributes ovadd and ovrem which may be used to
|
||||
have optional attributes ovadd, ovdep and ovrem which may be used to
|
||||
specify the OpenStep/OPENSTEP/MacOS-X versions at which the
|
||||
documented element was added to or removed from the API, and
|
||||
gvadd and gvrem which may be used to specify when an elment was
|
||||
added to or removed from the GNUstep API.<br />
|
||||
documented element was added to, deprecated in, or removed from
|
||||
the API, Similarly they have gvadd, gvdep and gvrem which may be
|
||||
used to specify when an elment was added to or removed from
|
||||
the API of the source code being documented
|
||||
(eg a gnustep library).<br />
|
||||
The definition elements are -
|
||||
</p>
|
||||
<deflist>
|
||||
|
|
Loading…
Reference in a new issue