Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/21dimensions/csharp-client
Client for EasyEasy.io cloud database
https://github.com/21dimensions/csharp-client
cloud database databases easyeasy orm orm-framework storage
Last synced: 7 days ago
JSON representation
Client for EasyEasy.io cloud database
- Host: GitHub
- URL: https://github.com/21dimensions/csharp-client
- Owner: 21dimensions
- Created: 2018-10-06T11:17:14.000Z (about 6 years ago)
- Default Branch: master
- Last Pushed: 2022-12-08T01:32:03.000Z (almost 2 years ago)
- Last Synced: 2023-03-21T12:42:30.784Z (over 1 year ago)
- Topics: cloud, database, databases, easyeasy, orm, orm-framework, storage
- Language: C#
- Homepage: http://easyeasy.io/
- Size: 11.7 KB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# EasyEasy.Client
## How to use
### Install with Nuget
```
Install-Package EasyEasy.Client
```### Initialize
```csharp YOUR_APP_KEY
var client = new Client("YOUR_APP_KEY");
```### Examples
```csharp
class Cat
{
// Id property is required
public string Id { get; set; }public string Name { get; set; }
public double Age { get; set; }
public IEnumerable Interests { get; set; }
}/////////////////
var cat = new Cat()
{
Name = "Sam",
Age = 1.5,
Interests = new string[] { "play", "eat" }
};// add new object
var id = await client.AddAsync(cat);// get object by id
cat = await client.GetOne(id);// update
cat.Age = 1.7;
await client.UpdateAsync(cat);// get filtered array of objects
var cats = await client.GetAsync(new { }); // return all cats
cats = await client.GetAsync(new { age=1.5 }); // 1.5 years old cats
cats = await client.GetAsync(new { age_gt=1.0 }); // cats older than 1 year
cats = await client.GetAsync(new { name_like="Sa*" }); // wildcard// paging
cats = await client.GetAsync(new { _start = 10, _count = 10 });//Learn more about filtering operators at: http://easyeasy.io/docs#/operators
//delete
await client.DeleteAsync(cat.Id)
```# Licence
ISC