jaguar_orm 0.2.0-dev copy "jaguar_orm: ^0.2.0-dev" to clipboard
jaguar_orm: ^0.2.0-dev copied to clipboard

outdatedDart 1 only

Source generated ORM for SQL/NoSQL

jaguar_orm #

Source generated ORM for SQL/NoSQL

Example #

import 'dart:async';
import 'package:jaguar_query/jaguar_query.dart';
import 'package:jaguar_orm/jaguar_orm.dart';

part 'basic_main.g.dart';

class Post {
  @PrimaryKey()
  String id;

  String author;

  String message;

  int likes;

  int replies;

  static String tableName = 'posts';
}

@GenBean()
class PostsBean extends _PostsBean implements Bean<Post> {
  PostsBean(Adapter adapter) : super(adapter);

  @Find()
  Future<Stream<Post>> findByAuthor(@WhereEq() String author) =>
      super.findByAuthor(author);

  @Update()
  Future updateByAuthor(@WhereEq() String author, @SetField() int replies) =>
      super.updateByAuthor(author, replies);

  @Delete()
  Future deleteByAuthor(@WhereEq() String author) =>
      super.deleteByAuthor(author);
}
22
likes
0
pub points
57%
popularity

Publisher

unverified uploader

Source generated ORM for SQL/NoSQL

Repository (GitHub)
View/report issues

License

unknown (LICENSE)

Dependencies

jaguar_query, quiver

More

Packages that depend on jaguar_orm