-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
14 changed files
with
182 additions
and
79 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,36 @@ | ||
/* | ||
* TIBCO JasperMobile for iOS | ||
* Copyright © 2005-2016 TIBCO Software, Inc. All rights reserved. | ||
* http://community.jaspersoft.com/project/jaspermobile-ios | ||
* | ||
* Unless you have purchased a commercial license agreement from Jaspersoft, | ||
* the following license terms apply: | ||
* | ||
* This program is free software: you can redistribute it and/or modify | ||
* it under the terms of the GNU Lesser General Public License as published by | ||
* the Free Software Foundation, either version 3 of the License, or | ||
* (at your option) any later version. | ||
* | ||
* This program is distributed in the hope that it will be useful, | ||
* but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
* GNU Lesser General Public License for more details. | ||
* | ||
* You should have received a copy of the GNU Lesser General Public License | ||
* along with this program. If not, see <http://www.gnu.org/licenses/lgpl>. | ||
*/ | ||
|
||
|
||
// | ||
// Created by Aleksandr Dakhno on 10/16/15. | ||
// JSErrorBuilder.h | ||
// TIBCO JasperMobile | ||
// | ||
|
||
/** | ||
@author Aleksandr Dakhno [email protected] | ||
@since 2.3 | ||
*/ | ||
|
||
#import <Foundation/Foundation.h> | ||
#import "JSConstants.h" | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
/* | ||
* TIBCO JasperMobile for iOS | ||
* Copyright © 2005-2016 TIBCO Software, Inc. All rights reserved. | ||
* http://community.jaspersoft.com/project/jaspermobile-ios | ||
* | ||
* Unless you have purchased a commercial license agreement from Jaspersoft, | ||
* the following license terms apply: | ||
* | ||
* This program is free software: you can redistribute it and/or modify | ||
* it under the terms of the GNU Lesser General Public License as published by | ||
* the Free Software Foundation, either version 3 of the License, or | ||
* (at your option) any later version. | ||
* | ||
* This program is distributed in the hope that it will be useful, | ||
* but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
* GNU Lesser General Public License for more details. | ||
* | ||
* You should have received a copy of the GNU Lesser General Public License | ||
* along with this program. If not, see <http://www.gnu.org/licenses/lgpl>. | ||
*/ | ||
|
||
|
||
// | ||
// NSString(JSURLEncodings).h | ||
// TIBCO JasperMobile | ||
// | ||
|
||
/** | ||
@author Alexey Gubarev [email protected] | ||
@since 2.5 | ||
*/ | ||
|
||
#import <Foundation/Foundation.h> | ||
|
||
@interface NSString(JSURLEncodings) | ||
|
||
- (nonnull NSString *)hostEncodedString; | ||
|
||
- (nonnull NSString *)queryEncodedString; | ||
@end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,50 @@ | ||
/* | ||
* TIBCO JasperMobile for iOS | ||
* Copyright © 2005-2016 TIBCO Software, Inc. All rights reserved. | ||
* http://community.jaspersoft.com/project/jaspermobile-ios | ||
* | ||
* Unless you have purchased a commercial license agreement from Jaspersoft, | ||
* the following license terms apply: | ||
* | ||
* This program is free software: you can redistribute it and/or modify | ||
* it under the terms of the GNU Lesser General Public License as published by | ||
* the Free Software Foundation, either version 3 of the License, or | ||
* (at your option) any later version. | ||
* | ||
* This program is distributed in the hope that it will be useful, | ||
* but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
* GNU Lesser General Public License for more details. | ||
* | ||
* You should have received a copy of the GNU Lesser General Public License | ||
* along with this program. If not, see <http://www.gnu.org/licenses/lgpl>. | ||
*/ | ||
|
||
|
||
// | ||
// NSString(JSURLEncodings).m | ||
// TIBCO JasperMobile | ||
// | ||
|
||
#import "NSString+JSURLEncodings.h" | ||
|
||
@implementation NSString(JSURLEncodings) | ||
|
||
- (nonnull NSString *)hostEncodedString { | ||
NSArray *components = [self componentsSeparatedByString:@"/"]; | ||
NSMutableArray *encodedComponentsArray = [NSMutableArray array]; | ||
for (NSString *component in components) { | ||
[encodedComponentsArray addObject:[component encodedStringWithCharSet:[NSCharacterSet URLHostAllowedCharacterSet]]]; | ||
} | ||
return [encodedComponentsArray componentsJoinedByString:@"/"]; | ||
} | ||
|
||
- (nonnull NSString *)queryEncodedString { | ||
return [self encodedStringWithCharSet:[NSCharacterSet URLQueryAllowedCharacterSet]]; | ||
} | ||
|
||
- (NSString *)encodedStringWithCharSet:(NSCharacterSet *)characterSet { | ||
return [self stringByAddingPercentEncodingWithAllowedCharacters:characterSet]; | ||
} | ||
|
||
@end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.