|
1 | 1 | /** |
2 | | - * Copyright (c) 2011, Tim Branyen @tbranyen <tim@tabdeveloper.com> |
3 | | - * @author Michael Robinson @codeofinterest <mike@pagesofinterest.net> |
4 | | - * |
5 | | - * Dual licensed under the MIT and GPL licenses. |
6 | | - */ |
| 2 | + * This code is auto-generated; unless you know what you're doing, do not modify! |
| 3 | + **/ |
7 | 4 |
|
8 | | -#ifndef TAG_H |
9 | | -#define TAG_H |
| 5 | +#ifndef GITTAG_H |
| 6 | +#define GITTAG_H |
10 | 7 |
|
| 8 | +#include <v8.h> |
11 | 9 | #include <node.h> |
| 10 | +#include <string> |
12 | 11 |
|
13 | 12 | #include "git2.h" |
14 | 13 |
|
15 | 14 | using namespace node; |
| 15 | +using namespace v8; |
16 | 16 |
|
17 | | -/** |
18 | | - * Class: GitTag |
19 | | - * Wrapper for libgit2 git_error. |
20 | | - */ |
21 | 17 | class GitTag : public ObjectWrap { |
22 | 18 | public: |
23 | | - /** |
24 | | - * Variable: constructor_template |
25 | | - * Used to create Node.js constructor. |
26 | | - */ |
27 | | - static v8::Persistent<v8::FunctionTemplate> constructor_template; |
28 | | - /** |
29 | | - * Function: Initialize |
30 | | - * Used to intialize the EventEmitter from Node.js |
31 | | - * |
32 | | - * Parameters: |
33 | | - * target - v8::Object the Node.js global module object |
34 | | - */ |
35 | | - static void Initialize(v8::Handle<v8::Object> target); |
36 | | - |
37 | | - protected: |
38 | | - /** |
39 | | - * Constructor: GitTag |
40 | | - */ |
41 | | - GitTag() {}; |
42 | | - /** |
43 | | - * Deconstructor: GitTag |
44 | | - */ |
45 | | - ~GitTag() {}; |
46 | | - /** |
47 | | - * Function: New |
48 | | - * |
49 | | - * Parameters: |
50 | | - * args v8::Arguments function call |
51 | | - * |
52 | | - * Returns: |
53 | | - * v8::Object args.This() |
54 | | - */ |
55 | | - static v8::Handle<v8::Value> New(const v8::Arguments& args); |
| 19 | + |
| 20 | + static Persistent<Function> constructor_template; |
| 21 | + static void Initialize (Handle<v8::Object> target); |
| 22 | + |
| 23 | + git_tag *GetValue(); |
| 24 | + |
| 25 | + private: |
| 26 | + GitTag(git_tag *raw); |
| 27 | + ~GitTag(); |
| 28 | + |
| 29 | + static Handle<Value> New(const Arguments& args); |
| 30 | + |
| 31 | + |
| 32 | + static Handle<Value> Lookup(const Arguments& args); |
| 33 | + static void LookupWork(uv_work_t* req); |
| 34 | + static void LookupAfterWork(uv_work_t* req); |
| 35 | + |
| 36 | + struct LookupBaton { |
| 37 | + uv_work_t request; |
| 38 | + const git_error* error; |
| 39 | + git_tag * out; |
| 40 | + Persistent<Value> repoReference; |
| 41 | + git_repository * repo; |
| 42 | + Persistent<Value> idReference; |
| 43 | + const git_oid * id; |
| 44 | + Persistent<Function> callback; |
| 45 | + }; |
| 46 | + static Handle<Value> Oid(const Arguments& args); |
| 47 | + static Handle<Value> Target(const Arguments& args); |
| 48 | + static void TargetWork(uv_work_t* req); |
| 49 | + static void TargetAfterWork(uv_work_t* req); |
| 50 | + |
| 51 | + struct TargetBaton { |
| 52 | + uv_work_t request; |
| 53 | + const git_error* error; |
| 54 | + git_object * target_out; |
| 55 | + Persistent<Value> tagReference; |
| 56 | + const git_tag * tag; |
| 57 | + Persistent<Function> callback; |
| 58 | + }; |
| 59 | + static Handle<Value> TargetId(const Arguments& args); |
| 60 | + static Handle<Value> TargetType(const Arguments& args); |
| 61 | + static Handle<Value> Name(const Arguments& args); |
| 62 | + static Handle<Value> Tagger(const Arguments& args); |
| 63 | + static Handle<Value> Message(const Arguments& args); |
| 64 | + static Handle<Value> Create(const Arguments& args); |
| 65 | + static void CreateWork(uv_work_t* req); |
| 66 | + static void CreateAfterWork(uv_work_t* req); |
| 67 | + |
| 68 | + struct CreateBaton { |
| 69 | + uv_work_t request; |
| 70 | + const git_error* error; |
| 71 | + git_oid * oid; |
| 72 | + Persistent<Value> repoReference; |
| 73 | + git_repository * repo; |
| 74 | + Persistent<Value> tag_nameReference; |
| 75 | + const char * tag_name; |
| 76 | + Persistent<Value> targetReference; |
| 77 | + const git_object * target; |
| 78 | + Persistent<Value> taggerReference; |
| 79 | + const git_signature * tagger; |
| 80 | + Persistent<Value> messageReference; |
| 81 | + const char * message; |
| 82 | + Persistent<Value> forceReference; |
| 83 | + int force; |
| 84 | + Persistent<Function> callback; |
| 85 | + }; |
| 86 | + static Handle<Value> CreateLightweight(const Arguments& args); |
| 87 | + static void CreateLightweightWork(uv_work_t* req); |
| 88 | + static void CreateLightweightAfterWork(uv_work_t* req); |
| 89 | + |
| 90 | + struct CreateLightweightBaton { |
| 91 | + uv_work_t request; |
| 92 | + const git_error* error; |
| 93 | + git_oid * oid; |
| 94 | + Persistent<Value> repoReference; |
| 95 | + git_repository * repo; |
| 96 | + Persistent<Value> tag_nameReference; |
| 97 | + const char * tag_name; |
| 98 | + Persistent<Value> targetReference; |
| 99 | + const git_object * target; |
| 100 | + Persistent<Value> forceReference; |
| 101 | + int force; |
| 102 | + Persistent<Function> callback; |
| 103 | + }; |
| 104 | + static Handle<Value> Delete(const Arguments& args); |
| 105 | + static Handle<Value> Peel(const Arguments& args); |
| 106 | + git_tag *raw; |
56 | 107 | }; |
57 | 108 |
|
58 | 109 | #endif |
0 commit comments