parse 0.0.1

  • README.md
  • CHANGELOG.md
  • Example
  • Installing
  • Versions
  • 37

parse_dart

A Parse Server library for Dart developers.

Created from templates made available by Stagehand under a BSD-style license.

Usage

This is still WIP, API might change

  • User Authentication works
  • No query builder yet
  • LiveQuery websocket works
  • Parse Object works

TODO:

  • Documentation
  • Query builder
  • ...

A simple usage example:

import 'package:parse/parse.dart';

main() {
  var awesome = new Parse();
}

Features and bugs

Please file feature requests and bugs at the issue tracker.

Changelog

0.0.1

  • Initial version, created by Stagehand

example/parse_example.dart

import 'package:parse/parse.dart';
import 'dart:async';
import 'dart:math';
main() async {
    var parse = new Parse(new Credentials("myappID"), "http://localhost", "ws://localhost");
    print('parse: ${parse.credentials}');
    var object = parse.object("this");
    var id = await object.get('objectId');
    print(id);
    var createdAt = await object.get('createdAt');
    print(createdAt);
    var created = await object.create({
      'firstName': "john",
      'lastName': "doe"
    });
    print(created);
    object = parse.object("this");
    print(object.objectId);
    object.set("age", 10);
    object.set("country", "CA");
    var createdUser = await object.create({"name": "user2"});
    object.set("age", 20);
    var saved = await object.save({"age": 30});
    var country = await object.get("country");
    print(country);
    await object.destroy();
    Future sleep2() async {
      await new Future.delayed(const Duration(seconds: 2), () => "1");
    }
    var lq = parse.liveQuery();
    await lq.subscribe("_User");
    lq.on('create', ((object)=>print(object)));
    for (var i = 0; i < 15; i++) {
      var user = parse.user();
      var rand = new Random();
      user.set("username", "user${rand.nextInt(100)}");
      user.set("password", "password");
      user.set("email", "user${rand.nextInt(100)}@example.com");
      user.set("phone", "+15144665532");
      print(user.objectId);
      var createdUser = await user.signUp();
      print("Created: $i");
    }

}

1. Depend on it

Add this to your package's pubspec.yaml file:


dependencies:
  parse: "^0.0.1"

2. Install it

You can install packages from the command line:

with pub:


$ pub get

with Flutter:


$ flutter packages get

Alternatively, your editor might support pub get or packages get. Check the docs for your editor to learn more.

3. Import it

Now in your Dart code, you can use:


import 'package:parse/parse.dart';
        
Version Uploaded Documentation Archive
0.0.1 Mar 24, 2018 Go to the documentation of parse 0.0.1 Download parse 0.0.1 archive

Analysis

We analyzed this package on Apr 23, 2018, and provided a score, details, and suggestions below. Analysis was completed with status completed using:

  • Dart: 2.0.0-dev.49.0
  • pana: 0.10.6

Scores

Popularity:
Describes how popular the package is relative to other packages. [more]
19 / 100
Health:
Code health derived from static analysis. [more]
32 / 100
Maintenance:
Reflects how tidy and up-to-date the package is. [more]
90 / 100
Overall score:
Weighted score of the above. [more]
37
Learn more about scoring.

Platforms

Detected platforms: Flutter, other

Primary library: package:parse/parse.dart with components: io.

Suggestions

  • Fix analysis and formatting issues.

    Analysis or formatting checks reported 18 errors 2 warnings 28 hints.

    Strong-mode analysis of lib/src/parse_http_client.dart failed with the following error:

    line: 15 col: 33
    Undefined class 'BaseRequest'.

    Strong-mode analysis of lib/src/parse_object.dart failed with the following error:

    line: 22 col: 34
    The method 'post' isn't defined for the class 'ParseHTTPClient'.

    Similar analysis of the following files failed:

    • lib/src/parse_user.dart (error)
    • lib/src/parse_livequery.dart (warning)
    • lib/src/parse_base.dart (hint)
    • lib/src/parse_query.dart (hint)
  • The description is too short.

    Add more detail about the package, what it does and what is its target use case. Try to write at least 60 characters.

  • Package is pre-v1 release.

    While there is nothing inherently wrong with versions of 0.*.*, it usually means that the author is still experimenting with the general direction API.

Dependencies

Package Constraint Resolved Available
Direct dependencies
Dart SDK >=1.20.1 <2.0.0
path ^1.4.1 1.5.1
websockets ^0.2.1+1 0.2.1+1
Transitive dependencies
analyzer 0.27.6 0.31.1
args 0.13.7 1.4.2
async 2.0.6
barback 0.15.2+15
charcode 1.1.1
cli_util 0.0.1+2 0.1.2+1
code_transformers 0.4.2+3 0.5.1+4
collection 1.14.9
convert 2.0.1
crypto 2.0.2+1
csslib 0.14.1
dart_style 0.2.11+1 1.0.10
glob 1.1.5
html 0.13.3
isolate 0.2.3 2.0.0
logging 0.11.3+1
package_config 1.0.3
plugin 0.2.0+2
pool 1.3.4
reflectable 0.5.4 2.0.0
source_maps 0.10.4
source_span 1.4.0
stack_trace 1.9.2
string_scanner 1.0.2
typed_data 1.1.5
utf 0.9.0+4
watcher 0.9.7+7
when 0.2.0
which 0.1.3
yaml 2.1.13
Dev dependencies
test ^0.12.0