haystack 0.4.21

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

haystack

Port of haystack java toolkit. Use it to connect and work with SkySpark. [Project Haystack]http://project-haystack.org/ defines a tagging model and REST API for sensor systems such as HVAC, lighting, and energy equipment. [SkySpark] is a project to serve your IoT data and make analytics.

To use this package you need installed SkySpark server (and apply a some license). Authentication methods are skipped now, so you can use this library from SkySpark pub folder. Just create in you SkySpark's folder root 'pub' directory and place here your app. It will be accessible by 'localhost_or_smth:80/pub/my_app.html'. Only client side is implemented at this moment, you can't use it from server or command-line apps.

Usage

A simple usage example (include this into HTML page):

import 'package:haystack/core.dart';
import 'package:haystack/hclient.dart';

final String uri = "http://localhost:8080/api/demo";
final String user = "haystack";
final String pass = "testpass";
HClient client;

main() {
  client = new HClient(uri, user, pass);
  client.open().then((_) => client.about()).then((HDict result) {
    print(result);
  });
}

Features and bugs

Please file feature requests and bugs at the issue tracker.

Changelog

0.4.21

  • Updated version header

0.4.20+3

  • Fixed grid dump with sub-grids

0.4.20+2

  • Added List implementation for HGrid (unmodifiable)

0.4.20+1

  • Fixed column's dis method

0.4.20

  • Fixed HGrid toString method

0.4.19

  • Fixed dollar sign string parsing

0.4.18

  • Added HList, HXStr,
  • Made HDict and HGrid HVals
  • Enhanced Zinc for nested data structures
  • Created HaystackTokenizer for parsing haystack types

0.4.17

  • test renamed to work with automatic testing

0.4.16

  • added HGrid.rows readonly getter
  • fixed tests to work with new test package

0.4.15

  • added tags

0.4.14

  • added map interface for HDict, HRow and HHisItem

0.4.13

  • fixed initial bool value error in HClientWatch class

0.4.11

  • Just fixed hclient library names conflict

0.4.10

  • Added HRemove singleton

0.4.0

  • Initial version, created by Dmitriy Vasilyev aka kelegorm

example/main.dart

// Copyright (c) 2015, <your name>. All rights reserved. Use of this source code
// is governed by a BSD-style license that can be found in the LICENSE file.

library haystack.example;

import 'package:haystack/core.dart';
import 'package:haystack/hclient.dart';

final String uri = "http://localhost:8080/api/demo";
final String user = "haystack";
final String pass = "testpass";
HClient client;

main() {
  client = new HClient(uri, user, pass);
  client.open().then((_) => client.about()).then((HDict result) {
    print(result);
  });
}

1. Depend on it

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


dependencies:
  haystack: "^0.4.21"

2. Install it

You can install packages from the command line:

with pub:


$ pub get

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

3. Import it

Now in your Dart code, you can use:


import 'package:haystack/core.dart';

import 'package:haystack/hclient.dart';
        
Version Uploaded Documentation Archive
0.4.21 Aug 4, 2017 Go to the documentation of haystack 0.4.21 Download haystack 0.4.21 archive
0.4.20+6 Apr 26, 2017 Go to the documentation of haystack 0.4.20+6 Download haystack 0.4.20+6 archive
0.4.20+5 Mar 16, 2017 Go to the documentation of haystack 0.4.20+5 Download haystack 0.4.20+5 archive
0.4.20+4 Mar 13, 2017 Go to the documentation of haystack 0.4.20+4 Download haystack 0.4.20+4 archive
0.4.20+2 Mar 8, 2017 Go to the documentation of haystack 0.4.20+2 Download haystack 0.4.20+2 archive
0.4.20+1 Feb 19, 2017 Go to the documentation of haystack 0.4.20+1 Download haystack 0.4.20+1 archive
0.4.20 Feb 3, 2017 Go to the documentation of haystack 0.4.20 Download haystack 0.4.20 archive
0.4.19 Nov 15, 2016 Go to the documentation of haystack 0.4.19 Download haystack 0.4.19 archive
0.4.18 Nov 15, 2016 Go to the documentation of haystack 0.4.18 Download haystack 0.4.18 archive
0.4.17 Dec 3, 2015 Go to the documentation of haystack 0.4.17 Download haystack 0.4.17 archive

All 21 versions...

Analysis

This feature is new.
We welcome feedback.

We analyzed this package, and provided a score, details, and suggestions below.

  • tool failures on Dec 6, 2017
  • Dart: 2.0.0-dev.8.0
  • pana: 0.7.3+1

Scores

Popularity:
Describes how popular the package is relative to other packages. [more]
35
Health:
Code health derived from static analysis. [more]
45
Maintenance:
Reflects how tidy and up-to-date the package is. [more]
51
Overall score:
Weighted score of the above. [more]
42

Platforms

Detected platforms:

Error(s) prevent platform classification.

Suggestions

  • Fix lib/src/HRow.dart.

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

    line: 52 col: 37
    The return type '_RowIterator' isn't a 'Iterator<DictEntry>', as defined by the method 'iterator'.

  • Fix lib/src/HHisItem.dart.

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

    line: 52 col: 37
    The return type '_HisItemIterator' isn't a 'Iterator<DictEntry>', as defined by the method 'iterator'.

  • Fix further 3 Dart files.

    Similar analysis of the following files failed:

    • lib/src/HDict.dart
    • lib/src/HGrid.dart
    • lib/src/io/HZincReader.dart

Dependencies

Package Constraint Resolved Available
Direct dependencies
collection any 1.14.3
intl any 0.15.2
quiver any 0.26.2
unicode_helper any 0.2.0
Transitive dependencies
matcher 0.12.1+4
meta 1.1.2
path 1.5.1
sparse_list 0.1.0
stack_trace 1.9.1
Dev dependencies
browser any
test >=0.12.18+2 <0.13.0