File tree Expand file tree Collapse file tree 2 files changed +20
-1
lines changed
Expand file tree Collapse file tree 2 files changed +20
-1
lines changed Original file line number Diff line number Diff line change 3939}
4040
4141- (id ) initWithData : (NSData *)theData isXML : (BOOL )isDataXML ;
42- - (id ) initWithHTMLData : (NSData *)theData ;
4342- (id ) initWithXMLData : (NSData *)theData ;
43+ - (id ) initWithHTMLData : (NSData *)theData ;
44+
45+ + (TFHpple *) hppleWithData : (NSData *)theData isXML : (BOOL )isDataXML ;
46+ + (TFHpple *) hppleWithXMLData : (NSData *)theData ;
47+ + (TFHpple *) hppleWithHTMLData : (NSData *)theData ;
48+
4449- (NSArray *) searchWithXPathQuery : (NSString *)xPathOrCSS ;
4550- (TFHppleElement *) peekAtSearchWithXPathQuery : (NSString *)xPathOrCSS ;
4651
Original file line number Diff line number Diff line change @@ -62,6 +62,20 @@ - (id) initWithHTMLData:(NSData *)theData
6262 return [self initWithData: theData isXML: NO ];
6363}
6464
65+ + (TFHpple *) hppleWithData : (NSData *)theData isXML : (BOOL )isDataXML {
66+ return [[[[self class ] alloc ] initWithData: theData isXML: isDataXML] autorelease ];
67+ }
68+
69+ + (TFHpple *) hppleWithHTMLData : (NSData *)theData {
70+ return [[self class ] hppleWithData: theData isXML: NO ];
71+ }
72+
73+ + (TFHpple *) hppleWithXMLData : (NSData *)theData {
74+ return [[self class ] hppleWithData: theData isXML: YES ];
75+ }
76+
77+ #pragma mark -
78+
6579// Returns all elements at xPath.
6680- (NSArray *) searchWithXPathQuery : (NSString *)xPathOrCSS
6781{
You can’t perform that action at this time.
0 commit comments