Skip to content

Parse properties, superclass and conforming protocols - #393

Open
Eskils wants to merge 8 commits into
DanielMSchmidt:masterfrom
Eskils:master
Open

Parse properties, superclass and conforming protocols#393
Eskils wants to merge 8 commits into
DanielMSchmidt:masterfrom
Eskils:master

Conversation

@Eskils

@Eskils Eskils commented Aug 1, 2024

Copy link
Copy Markdown

This PR aims to implement support for parsing @\property declarations, an interface’s superclass and conforming protocols.

The following header-file:

@interface BasicName : NSObject <Ponies, Foo>

// Another comment
@property(nonatomic, readonly) NSArray<NSString *> titles;


// This is the comment of basic method one
- (NSInteger)basicMethodOne;

@end

…will be parsed into:

{
    "name": "BasicName",
    "superclass": "NSObject",
    "protocols": ["Ponies", "Foo"],
    "properties": [
        {
	    "attributes": ["nonatomic", "readonly"],
	    "name": "titles",
	    "type": "NSArray<NSString *>"
        }
    ],
    "methods": [
        {
	    "args": [],
	    "comment": "This is the comment of basic method one",
	    "name": "basicMethodOne",
	    "returnType": "NSInteger"
        }
    ]
}

Please let me know if there is anything you would like to change or supplement.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant