Skip to content

Commit

Permalink
init
Browse files Browse the repository at this point in the history
  • Loading branch information
rnystrom committed Oct 3, 2012
1 parent c925842 commit a3b761e
Show file tree
Hide file tree
Showing 116 changed files with 10,628 additions and 42 deletions.
15 changes: 15 additions & 0 deletions .gitmodules
@@ -0,0 +1,15 @@
[submodule "AFNetworking"]
path = AFNetworking
url = https://github.com/AFNetworking/AFNetworking.git
[submodule "CocoaLumberjack"]
path = CocoaLumberjack
url = https://github.com/robbiehanson/CocoaLumberjack.git
[submodule "specta"]
path = specta
url = https://github.com/petejkim/specta.git
[submodule "SkyLab"]
path = SkyLab
url = https://github.com/mattt/SkyLab.git
[submodule "MBProgressHUD"]
path = MBProgressHUD
url = https://github.com/jdg/MBProgressHUD.git
1 change: 1 addition & 0 deletions AFNetworking
Submodule AFNetworking added at b118e9
1 change: 1 addition & 0 deletions CocoaLumberjack
Submodule CocoaLumberjack added at 536c68
90 changes: 90 additions & 0 deletions FlurryAnalytics/FlurryAnalytics.h
@@ -0,0 +1,90 @@
//
// FlurryAnalytics.h
// Flurry iOS Analytics Agent
//
// Copyright 2009-2011 Flurry, Inc. All rights reserved.
//
// Methods in this header file are for use with Flurry Analytics

#import <UIKit/UIKit.h>

/*!
* \brief Provides all available methods for defining and reporting Analytics from use
* of your app.
*
* Set of methods that allow developers to capture detailed, aggregate information
* regarding the use of their app by end users.
* \author 2009 - 2011 Flurry, Inc. All Rights Reserved.
*/

/*!
* @class FlurryAnalytics
* @abstract Provides all available methods for defining and reporting Analytics from use
* of your app.
* @discussion Set of methods that allow developers to capture detailed, aggregate information
* regarding the use of their app by end users.
* @helps This class provides methods necessary for correct function of FlurryAppCircle.h.
* For information on how to use Flurry's AppCircle SDK to
* attract high-quality users and monetize your user base see http://wiki.flurry.com/index.php?title=AppCircle.
*
*/

@interface FlurryAnalytics : NSObject {
}

/*
optional sdk settings that should be called before start session
*/
+ (void)setAppVersion:(NSString *)version; // override the app version
+ (NSString *)getFlurryAgentVersion; // get the Flurry Agent version number
+ (void)setShowErrorInLogEnabled:(BOOL)value; // default is NO
+ (void)setDebugLogEnabled:(BOOL)value; // generate debug logs for Flurry support, default is NO
+ (void)setSessionContinueSeconds:(int)seconds; // default is 10 seconds
+ (void)setSecureTransportEnabled:(BOOL)value; // set data to be sent over SSL, default is NO

/*
start session, attempt to send saved sessions to server
*/
+ (void)startSession:(NSString *)apiKey;

/*
log events or errors after session has started
*/
+ (void)logEvent:(NSString *)eventName;
+ (void)logEvent:(NSString *)eventName withParameters:(NSDictionary *)parameters;
+ (void)logError:(NSString *)errorID message:(NSString *)message exception:(NSException *)exception;
+ (void)logError:(NSString *)errorID message:(NSString *)message error:(NSError *)error;

/*
start or end timed events
*/
+ (void)logEvent:(NSString *)eventName timed:(BOOL)timed;
+ (void)logEvent:(NSString *)eventName withParameters:(NSDictionary *)parameters timed:(BOOL)timed;
+ (void)endTimedEvent:(NSString *)eventName withParameters:(NSDictionary *)parameters; // non-nil parameters will update the parameters

/*
count page views
*/
+ (void)logAllPageViews:(id)target; // automatically track page view on UINavigationController or UITabBarController
+ (void)logPageView; // manually increment page view by 1

/*
set user info
*/
+ (void)setUserID:(NSString *)userID; // user's id in your system
+ (void)setAge:(int)age; // user's age in years
+ (void)setGender:(NSString *)gender; // user's gender m or f

/*
set location information
*/
+ (void)setLatitude:(double)latitude longitude:(double)longitude horizontalAccuracy:(float)horizontalAccuracy verticalAccuracy:(float)verticalAccuracy;

/*
optional session settings that can be changed after start session
*/
+ (void)setSessionReportsOnCloseEnabled:(BOOL)sendSessionReportsOnClose; // default is YES
+ (void)setSessionReportsOnPauseEnabled:(BOOL)setSessionReportsOnPauseEnabled; // default is NO
+ (void)setEventLoggingEnabled:(BOOL)value; // default is YES

@end
Binary file added FlurryAnalytics/libFlurryAnalytics.a
Binary file not shown.
1 change: 1 addition & 0 deletions MBProgressHUD
Submodule MBProgressHUD added at 43771a
1 change: 1 addition & 0 deletions Parse.framework/Headers
1 change: 1 addition & 0 deletions Parse.framework/Parse
1 change: 1 addition & 0 deletions Parse.framework/Resources
204 changes: 204 additions & 0 deletions Parse.framework/Versions/1.1.11/Headers/PFACL.h
@@ -0,0 +1,204 @@
// PFACL.h
// Copyright 2011 Parse, Inc. All rights reserved.

#import <Foundation/Foundation.h>

@class PFUser;
@class PFRole;

/*!
A PFACL is used to control which users can access or modify a particular
object. Each PFObject can have its own PFACL. You can grant
read and write permissions separately to specific users, to groups of users
that belong to roles, or you can grant permissions to "the public" so that,
for example, any user could read a particular object but only a particular
set of users could write to that object.
*/
@interface PFACL : NSObject <NSCopying> {
@private
NSMutableDictionary *permissionsById;
BOOL shared;
PFUser *unresolvedUser;
void (^userResolutionListener)(id result, NSError *error);
}

/** @name Creating an ACL */

/*!
Creates an ACL with no permissions granted.
*/
+ (PFACL *)ACL;

/*!
Creates an ACL where only the provided user has access.
*/
+ (PFACL *)ACLWithUser:(PFUser *)user;

/** @name Controlling Public Access */

/*!
Set whether the public is allowed to read this object.
*/
- (void)setPublicReadAccess:(BOOL)allowed;

/*!
Gets whether the public is allowed to read this object.
*/
- (BOOL)getPublicReadAccess;

/*!
Set whether the public is allowed to write this object.
*/
- (void)setPublicWriteAccess:(BOOL)allowed;

/*!
Gets whether the public is allowed to write this object.
*/
- (BOOL)getPublicWriteAccess;

/** @name Controlling Access Per-User */

/*!
Set whether the given user id is allowed to read this object.
*/
- (void)setReadAccess:(BOOL)allowed forUserId:(NSString *)userId;

/*!
Gets whether the given user id is *explicitly* allowed to read this object.
Even if this returns NO, the user may still be able to access it if getPublicReadAccess returns YES
or if the user belongs to a role that has access.
*/
- (BOOL)getReadAccessForUserId:(NSString *)userId;

/*!
Set whether the given user id is allowed to write this object.
*/
- (void)setWriteAccess:(BOOL)allowed forUserId:(NSString *)userId;

/*!
Gets whether the given user id is *explicitly* allowed to write this object.
Even if this returns NO, the user may still be able to write it if getPublicWriteAccess returns YES
or if the user belongs to a role that has access.
*/
- (BOOL)getWriteAccessForUserId:(NSString *)userId;

/*!
Set whether the given user is allowed to read this object.
*/
- (void)setReadAccess:(BOOL)allowed forUser:(PFUser *)user;

/*!
Gets whether the given user is *explicitly* allowed to read this object.
Even if this returns NO, the user may still be able to access it if getPublicReadAccess returns YES
or if the user belongs to a role that has access.
*/
- (BOOL)getReadAccessForUser:(PFUser *)user;

/*!
Set whether the given user is allowed to write this object.
*/
- (void)setWriteAccess:(BOOL)allowed forUser:(PFUser *)user;

/*!
Gets whether the given user is *explicitly* allowed to write this object.
Even if this returns NO, the user may still be able to write it if getPublicWriteAccess returns YES
or if the user belongs to a role that has access.
*/
- (BOOL)getWriteAccessForUser:(PFUser *)user;

/** @name Controlling Access Per-Role */

/*!
Get whether users belonging to the role with the given name are allowed
to read this object. Even if this returns false, the role may still
be able to read it if a parent role has read access.
@param name The name of the role.
@return YES if the role has read access. NO otherwise.
*/
- (BOOL)getReadAccessForRoleWithName:(NSString *)name;

/*!
Set whether users belonging to the role with the given name are allowed
to read this object.
@param name The name of the role.
@param allowed Whether the given role can read this object.
*/
- (void)setReadAccess:(BOOL)allowed forRoleWithName:(NSString *)name;

/*!
Get whether users belonging to the role with the given name are allowed
to write this object. Even if this returns false, the role may still
be able to write it if a parent role has write access.
@param name The name of the role.
@return YES if the role has read access. NO otherwise.
*/
- (BOOL)getWriteAccessForRoleWithName:(NSString *)name;

/*!
Set whether users belonging to the role with the given name are allowed
to write this object.
@param name The name of the role.
@param allowed Whether the given role can write this object.
*/
- (void)setWriteAccess:(BOOL)allowed forRoleWithName:(NSString *)name;

/*!
Get whether users belonging to the given role are allowed to read this
object. Even if this returns NO, the role may still be able to
read it if a parent role has read access. The role must already be saved on
the server and its data must have been fetched in order to use this method.
@param roleName The name of the role.
@return YES if the role has read access. NO otherwise.
*/
- (BOOL)getReadAccessForRole:(PFRole *)role;

/*!
Set whether users belonging to the given role are allowed to read this
object. The role must already be saved on the server and its data must have
been fetched in order to use this method.
@param role The role to assign access.
@param allowed Whether the given role can read this object.
*/
- (void)setReadAccess:(BOOL)allowed forRole:(PFRole *)role;

/*!
Get whether users belonging to the given role are allowed to write this
object. Even if this returns NO, the role may still be able to
write it if a parent role has write access. The role must already be saved on
the server and its data must have been fetched in order to use this method.
@param roleName The name of the role.
@return YES if the role has write access. NO otherwise.
*/
- (BOOL)getWriteAccessForRole:(PFRole *)role;

/*!
Set whether users belonging to the given role are allowed to write this
object. The role must already be saved on the server and its data must have
been fetched in order to use this method.
@param role The role to assign access.
@param allowed Whether the given role can write this object.
*/
- (void)setWriteAccess:(BOOL)allowed forRole:(PFRole *)role;

/** @name Setting Access Defaults */

/*!
Sets a default ACL that will be applied to all PFObjects when they are created.
@param acl The ACL to use as a template for all PFObjects created after setDefaultACL has been called.
This value will be copied and used as a template for the creation of new ACLs, so changes to the
instance after setDefaultACL has been called will not be reflected in new PFObjects.
@param currentUserAccess If true, the PFACL that is applied to newly-created PFObjects will
provide read and write access to the currentUser at the time of creation. If false,
the provided ACL will be used without modification. If acl is nil, this value is ignored.
*/
+ (void)setDefaultACL:(PFACL *)acl withAccessForCurrentUser:(BOOL)currentUserAccess;

@end
57 changes: 57 additions & 0 deletions Parse.framework/Versions/1.1.11/Headers/PFAnonymousUtils.h
@@ -0,0 +1,57 @@
//
// PFAnonymousUtils.h
// Parse
//
// Created by David Poll on 3/20/12.
// Copyright (c) 2012 Parse, Inc. All rights reserved.
//

#import <Foundation/Foundation.h>
#import "PFUser.h"
#import "PFConstants.h"

/*!
Provides utility functions for working with Anonymously logged-in users. Anonymous users have some unique characteristics:
<ul>
<li>Anonymous users don't need a user name or password.</li>
<li>Once logged out, an anonymous user cannot be recovered.</li>
<li>When the current user is anonymous, the following methods can be used to switch to a different user or convert the
anonymous user into a regular one:
<ul>
<li>signUp converts an anonymous user to a standard user with the given username and password.
Data associated with the anonymous user is retained.</li>
<li>logIn switches users without converting the anonymous user. Data associated with the anonymous user will be lost.</li>
<li>Service logIn (e.g. Facebook, Twitter) will attempt to convert the anonymous user into a standard user by linking it to the service.
If a user already exists that is linked to the service, it will instead switch to the existing user.</li>
<li>Service linking (e.g. Facebook, Twitter) will convert the anonymous user into a standard user by linking it to the service.</li>
</ul>
</ul>
*/
@interface PFAnonymousUtils : NSObject

/*! @name Creating an Anonymous User */

/*!
Creates an anonymous user.
@param block The block to execute when anonymous user creation is complete. The block should have the following argument signature:
(PFUser *user, NSError *error)
*/
+ (void)logInWithBlock:(PFUserResultBlock)block;

/*!
Creates an anonymous user. The selector for the callback should look like: (PFUser *)user error:(NSError *)error
@param target Target object for the selector.
@param selector The selector that will be called when the asynchronous request is complete.
*/
+ (void)logInWithTarget:(id)target selector:(SEL)selector;

/*! @name Determining Whether a PFUser is Anonymous */

/*!
Whether the user is logged in anonymously.
@param user User to check for anonymity. The user must be logged in on this device.
@result True if the user is anonymous. False if the user is not the current user or is not anonymous.
*/
+ (BOOL)isLinkedWithUser:(PFUser *)user;

@end

0 comments on commit a3b761e

Please sign in to comment.