Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Newer
Older
100644 66 lines (53 sloc) 1.927 kb
05eedb5 @itod initial add
authored
1 // Copyright 2010 Todd Ditchendorf
2 //
3 // Licensed under the Apache License, Version 2.0 (the "License");
4 // you may not use this file except in compliance with the License.
5 // You may obtain a copy of the License at
6 //
7 // http://www.apache.org/licenses/LICENSE-2.0
8 //
9 // Unless required by applicable law or agreed to in writing, software
10 // distributed under the License is distributed on an "AS IS" BASIS,
11 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 // See the License for the specific language governing permissions and
13 // limitations under the License.
14
15 #import "PKJSTokenizerState.h"
16 #import "PKJSUtils.h"
17 #import "PKJSToken.h"
18 #import <ParseKit/PKTokenizerState.h>
19 #import <ParseKit/PKToken.h>
20
21 #pragma mark -
22 #pragma mark Methods
23
24 #pragma mark -
25 #pragma mark Properties
26
27 #pragma mark -
28 #pragma mark Initializer/Finalizer
29
30 static void PKTokenizerState_initialize(JSContextRef ctx, JSObjectRef this) {
31
32 }
33
34 static void PKTokenizerState_finalize(JSObjectRef this) {
35 PKTokenizerState *data = (PKTokenizerState *)JSObjectGetPrivate(this);
36 [data autorelease];
37 }
38
39 static JSStaticFunction PKTokenizerState_staticFunctions[] = {
40 { 0, 0, 0 }
41 };
42
43 static JSStaticValue PKTokenizerState_staticValues[] = {
44 { 0, 0, 0, 0 }
45 };
46
47 #pragma mark -
48 #pragma mark Public
49
50 JSClassRef PKTokenizerState_class(JSContextRef ctx) {
51 static JSClassRef jsClass = NULL;
52 if (!jsClass) {
53 JSClassDefinition def = kJSClassDefinitionEmpty;
54 def.staticFunctions = PKTokenizerState_staticFunctions;
55 def.staticValues = PKTokenizerState_staticValues;
56 def.initialize = PKTokenizerState_initialize;
57 def.finalize = PKTokenizerState_finalize;
58 jsClass = JSClassCreate(&def);
59 }
60 return jsClass;
61 }
62
63 JSObjectRef PKTokenizerState_new(JSContextRef ctx, void *data) {
64 return JSObjectMake(ctx, PKTokenizerState_class(ctx), data);
65 }
Something went wrong with that request. Please try again.