Skip to content

Commit f42ad6c

Browse files
Initial commit
1 parent c2bd22b commit f42ad6c

File tree

204 files changed

+10682
-0
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

204 files changed

+10682
-0
lines changed

.gitignore

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
.svn

Intuit.QuickBase.Client/AppDtm.cs

+40
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
/*
2+
* Copyright © 2010 Intuit Inc. All rights reserved.
3+
* All rights reserved. This program and the accompanying materials
4+
* are made available under the terms of the Eclipse Public License v1.0
5+
* which accompanies this distribution, and is available at
6+
* http://www.opensource.org/licenses/eclipse-1.0.php
7+
*/
8+
using System.Collections.Generic;
9+
10+
namespace Intuit.QuickBase.Client
11+
{
12+
public class AppDtm : Dtm
13+
{
14+
private readonly List<TableDtm> _tableDtm;
15+
16+
public AppDtm(string dbid, long lastModifiedTime, long lastRecModTime, long requestTime, long requestNextAllowedTime)
17+
: base(dbid, lastModifiedTime, lastRecModTime)
18+
{
19+
RequestTime = requestTime;
20+
RequestNextAllowedTime = requestNextAllowedTime;
21+
_tableDtm = new List<TableDtm>();
22+
}
23+
24+
public long RequestTime { get; private set; }
25+
public long RequestNextAllowedTime { get; private set; }
26+
27+
public void AddTable(string dbid, long lastModifiedTime, long lastRecModTime)
28+
{
29+
_tableDtm.Add(new TableDtm(dbid, lastModifiedTime, lastRecModTime));
30+
}
31+
32+
public List<TableDtm> Tables
33+
{
34+
get
35+
{
36+
return _tableDtm;
37+
}
38+
}
39+
}
40+
}

Intuit.QuickBase.Client/AppInfo.cs

+34
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
/*
2+
* Copyright © 2010 Intuit Inc. All rights reserved.
3+
* All rights reserved. This program and the accompanying materials
4+
* are made available under the terms of the Eclipse Public License v1.0
5+
* which accompanies this distribution, and is available at
6+
* http://www.opensource.org/licenses/eclipse-1.0.php
7+
*/
8+
namespace Intuit.QuickBase.Client
9+
{
10+
public class AppInfo : IDBInfo
11+
{
12+
public AppInfo(string dbName, long lastRecModTime, long lastModifiedTime, long createTime,
13+
int numRecords, string mgrId, string mgrName, string version)
14+
{
15+
DbName = dbName;
16+
LastRecModtime = lastRecModTime;
17+
LastModifiedTime = lastModifiedTime;
18+
CreateTime = createTime;
19+
NumRecords = numRecords;
20+
MgrId = mgrId;
21+
MgrName = mgrName;
22+
Version = version;
23+
}
24+
25+
public string DbName { get; private set; }
26+
public string Version { get; private set; }
27+
public string MgrName { get; private set; }
28+
public string MgrId { get; private set; }
29+
public int NumRecords { get; private set; }
30+
public long CreateTime { get; private set; }
31+
public long LastModifiedTime { get; private set; }
32+
public long LastRecModtime { get; private set; }
33+
}
34+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,73 @@
1+
/*
2+
* Copyright © 2010 Intuit Inc. All rights reserved.
3+
* All rights reserved. This program and the accompanying materials
4+
* are made available under the terms of the Eclipse Public License v1.0
5+
* which accompanies this distribution, and is available at
6+
* http://www.opensource.org/licenses/eclipse-1.0.php
7+
*/
8+
namespace Intuit.QuickBase.Client
9+
{
10+
public enum ComparisonOperator
11+
{
12+
///<summary>
13+
/// Contains
14+
///</summary>
15+
CT,
16+
///<summary>
17+
/// Does not contain
18+
///</summary>
19+
XCT,
20+
///<summary>
21+
/// Is
22+
///</summary>
23+
EX,
24+
///<summary>
25+
/// True Value
26+
///</summary>
27+
TV,
28+
///<summary>
29+
/// Is not
30+
///</summary>
31+
XEX,
32+
///<summary>
33+
/// Starts with
34+
///</summary>
35+
SW,
36+
///<summary>
37+
/// Does not start with
38+
///</summary>
39+
XSW,
40+
///<summary>
41+
/// Is before
42+
///</summary>
43+
BF,
44+
///<summary>
45+
/// Is on or before
46+
///</summary>
47+
OBF,
48+
///<summary>
49+
/// Is after
50+
///</summary>
51+
AF,
52+
///<summary>
53+
/// Is on or after
54+
///</summary>
55+
OAF,
56+
///<summary>
57+
/// Is less than
58+
///</summary>
59+
LT,
60+
///<summary>
61+
/// Is less than or equal to
62+
///</summary>
63+
LTE,
64+
///<summary>
65+
/// Is greater than
66+
///</summary>
67+
GT,
68+
///<summary>
69+
/// Is greater than or equal to
70+
///</summary>
71+
GTE
72+
}
73+
}

Intuit.QuickBase.Client/Dtm.cs

+23
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
/*
2+
* Copyright © 2010 Intuit Inc. All rights reserved.
3+
* All rights reserved. This program and the accompanying materials
4+
* are made available under the terms of the Eclipse Public License v1.0
5+
* which accompanies this distribution, and is available at
6+
* http://www.opensource.org/licenses/eclipse-1.0.php
7+
*/
8+
namespace Intuit.QuickBase.Client
9+
{
10+
public abstract class Dtm
11+
{
12+
protected Dtm(string dbid, long lastModifiedTime, long lastRecModTime)
13+
{
14+
Dbid = dbid;
15+
LastModifiedTime = lastModifiedTime;
16+
LastRecModTime = lastRecModTime;
17+
}
18+
19+
public string Dbid { get; private set; }
20+
public long LastModifiedTime { get; private set; }
21+
public long LastRecModTime { get; private set; }
22+
}
23+
}
+35
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
/*
2+
* Copyright © 2010 Intuit Inc. All rights reserved.
3+
* All rights reserved. This program and the accompanying materials
4+
* are made available under the terms of the Eclipse Public License v1.0
5+
* which accompanies this distribution, and is available at
6+
* http://www.opensource.org/licenses/eclipse-1.0.php
7+
*/
8+
using System.Collections.Generic;
9+
10+
namespace Intuit.QuickBase.Client
11+
{
12+
public class GrantedAppsInfo : GrantedInfo
13+
{
14+
private readonly List<GrantedTablesInfo> _grantedTables;
15+
16+
public GrantedAppsInfo(string name, string dbid)
17+
: base(name, dbid)
18+
{
19+
_grantedTables = new List<GrantedTablesInfo>();
20+
}
21+
22+
public void AddTable(string name, string dbid)
23+
{
24+
_grantedTables.Add(new GrantedTablesInfo(name, dbid));
25+
}
26+
27+
public List<GrantedTablesInfo> GrantedTables
28+
{
29+
get
30+
{
31+
return _grantedTables;
32+
}
33+
}
34+
}
35+
}
+21
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
/*
2+
* Copyright © 2010 Intuit Inc. All rights reserved.
3+
* All rights reserved. This program and the accompanying materials
4+
* are made available under the terms of the Eclipse Public License v1.0
5+
* which accompanies this distribution, and is available at
6+
* http://www.opensource.org/licenses/eclipse-1.0.php
7+
*/
8+
namespace Intuit.QuickBase.Client
9+
{
10+
public abstract class GrantedInfo
11+
{
12+
protected GrantedInfo(string name, string dbid)
13+
{
14+
Name = name;
15+
Dbid = dbid;
16+
}
17+
18+
public string Name { get; private set; }
19+
public string Dbid { get; private set; }
20+
}
21+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
/*
2+
* Copyright © 2010 Intuit Inc. All rights reserved.
3+
* All rights reserved. This program and the accompanying materials
4+
* are made available under the terms of the Eclipse Public License v1.0
5+
* which accompanies this distribution, and is available at
6+
* http://www.opensource.org/licenses/eclipse-1.0.php
7+
*/
8+
namespace Intuit.QuickBase.Client
9+
{
10+
public class GrantedTablesInfo : GrantedInfo
11+
{
12+
public GrantedTablesInfo(string name, string dbid)
13+
: base(name, dbid) { }
14+
}
15+
}

Intuit.QuickBase.Client/IDBInfo.cs

+21
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
/*
2+
* Copyright © 2010 Intuit Inc. All rights reserved.
3+
* All rights reserved. This program and the accompanying materials
4+
* are made available under the terms of the Eclipse Public License v1.0
5+
* which accompanies this distribution, and is available at
6+
* http://www.opensource.org/licenses/eclipse-1.0.php
7+
*/
8+
namespace Intuit.QuickBase.Client
9+
{
10+
public interface IDBInfo
11+
{
12+
string DbName { get; }
13+
string Version { get; }
14+
string MgrName { get; }
15+
string MgrId { get; }
16+
int NumRecords { get; }
17+
long CreateTime { get; }
18+
long LastModifiedTime { get; }
19+
long LastRecModtime { get; }
20+
}
21+
}
+37
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
/*
2+
* Copyright © 2010 Intuit Inc. All rights reserved.
3+
* All rights reserved. This program and the accompanying materials
4+
* are made available under the terms of the Eclipse Public License v1.0
5+
* which accompanies this distribution, and is available at
6+
* http://www.opensource.org/licenses/eclipse-1.0.php
7+
*/
8+
using System.Collections.Generic;
9+
using System.Xml.XPath;
10+
11+
namespace Intuit.QuickBase.Client
12+
{
13+
public interface IQApplication
14+
{
15+
string Token { get; }
16+
string ApplicationName { get; }
17+
string ApplicationId { get; }
18+
IQClient Client { get; }
19+
void Disconnect();
20+
AppInfo GetApplicationInfo();
21+
XPathDocument GetApplicationSchema();
22+
string CloneApplication(string qbNewName, string qbNewDescription, CloneData cloneData);
23+
void RenameApplication(string qbNewName);
24+
void DeleteApplication();
25+
UserInfo GetUserInfo(string email);
26+
UserRoleInfo GetUserRole(string userId);
27+
List<UserRoleInfo> UserRoles();
28+
IQTable NewTable(string tableName, string pNoun);
29+
void DeleteTable(IQTable table);
30+
IQTable GetTable(string dbid);
31+
Dictionary<string, IQTable> GetTables();
32+
AppDtm GetApplicationDataTimeInfo();
33+
List<GrantedAppsInfo> GrantedDBs();
34+
string ToString();
35+
void ClearTables();
36+
}
37+
}

Intuit.QuickBase.Client/IQClient.cs

+27
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
/*
2+
* Copyright © 2013 Intuit Inc. All rights reserved.
3+
* All rights reserved. This program and the accompanying materials
4+
* are made available under the terms of the Eclipse Public License v1.0
5+
* which accompanies this distribution, and is available at
6+
* http://www.opensource.org/licenses/eclipse-1.0.php
7+
*/
8+
using System.Collections.Generic;
9+
10+
namespace Intuit.QuickBase.Client
11+
{
12+
public interface IQClient
13+
{
14+
IQApplication Connect(string applicationId, string token);
15+
IQApplication Connect(string applicationId);
16+
void Disconnect(IQApplication application);
17+
void Logout();
18+
IQApplication CreateApplication(string qbName, string qbDescription, CreateApplicationToken createApplicationToken);
19+
List<string> FindApplication(string qbName);
20+
string Ticket { get; }
21+
string ClientUserName { get; }
22+
string ClientPassword { get; }
23+
string AdminUserName { get; }
24+
string AdminPassword { get; }
25+
string AccountDomain { get; }
26+
}
27+
}

Intuit.QuickBase.Client/IQColumn.cs

+22
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
/*
2+
* Copyright © 2010 Intuit Inc. All rights reserved.
3+
* All rights reserved. This program and the accompanying materials
4+
* are made available under the terms of the Eclipse Public License v1.0
5+
* which accompanies this distribution, and is available at
6+
* http://www.opensource.org/licenses/eclipse-1.0.php
7+
*/
8+
using Intuit.QuickBase.Core;
9+
10+
namespace Intuit.QuickBase.Client
11+
{
12+
public interface IQColumn
13+
{
14+
int ColumnId { get; set; }
15+
string ColumnName { get; set; }
16+
FieldType ColumnType { get; set; }
17+
bool Equals(IQColumn column);
18+
bool Equals(object obj);
19+
int GetHashCode();
20+
string ToString();
21+
}
22+
}

Intuit.QuickBase.Client/IQRecord.cs

+25
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
/*
2+
* Copyright © 2010 Intuit Inc. All rights reserved.
3+
* All rights reserved. This program and the accompanying materials
4+
* are made available under the terms of the Eclipse Public License v1.0
5+
* which accompanies this distribution, and is available at
6+
* http://www.opensource.org/licenses/eclipse-1.0.php
7+
*/
8+
namespace Intuit.QuickBase.Client
9+
{
10+
public interface IQRecord
11+
{
12+
int RecordId { get; }
13+
RecordState RecordState { get; }
14+
bool IsOnServer { get; }
15+
string this[int index] { get; set; }
16+
string this[string columnName] { get; set; }
17+
void AcceptChanges();
18+
void DownloadFile(string columnName, string path, int versionId);
19+
void ChangeOwnerTo(string newOwner);
20+
bool Equals(IQRecord record);
21+
bool Equals(object obj);
22+
int GetHashCode();
23+
string ToString();
24+
}
25+
}

0 commit comments

Comments
 (0)