stringprocess 1.0.2

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

stringprocess

A string library for common string operations and general text helper functions.

Status

Build Status

Usage

A simple usage example:

import 'package:stringprocess/stringprocess.dart';

main() {
  // A few simple examples.
  StringProcessor tps = new StringProcessor();

  // Print the numbers 1 to 10.
  print(tps.getSequenceString(1, 10, 1));

  // Repeat Something!
  print(tps.getRepeatedString("Mine!", 42));

  // Word count.
  print(tps.getWordCount("Dart is Awesome and cool!"));

  // Line count.
  print(tps.getLineCount("hello\ngood\nevening\nwelcome!\n"));
}

Unit Testing

  • pub run test

Check source code formatting:

  • dartfmt -n .

Acknowledgements

This package makes use of the following Dart packages:

  • html_unescape
  • markdown

Features and bugs

Please file feature requests and bugs!

Changelog

1.0.2

  • Splice function covers cases where splice values are outside string length.

1.0.1

  • Splice changes.
  • Refactor line splitting.

1.0.0

  • Bump to version 1 as package is stable.
  • Added splice method to chop characters off start/end of a line.

0.0.9

  • trimAllSpaces function added.

0.0.8

  • Minor doc updated and SDK constraint changed.

0.0.7

  • Added simple numbering method.

0.0.6

  • Improved split method

0.0.5

  • Added split method

0.0.4

  • Added deleteLinesNotContaining method

0.0.3

  • Update to prepare for Dart 2.0.

0.0.2

  • Documentation added.
  • Minor refactoring and renaming.

0.0.1

  • Initial version extracted from NP8080.

example/stringprocess_example.dart

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

import 'package:stringprocess/stringprocess.dart';

main() {
  // A few simple examples.
  StringProcessor tps = new StringProcessor();

  // Print the numbers 1 to 10.
  print(tps.generateSequenceString(1, 10, 1));

  // Repeat Something!
  print(tps.generateRepeatedString("Mine!", 42));

  // Word count.
  print(tps.getWordCount("Dart is Awesome and cool!"));

  // Line count.
  print(tps.getLineCount("hello\ngood\nevening\nwelcome!\n"));
}

1. Depend on it

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


dependencies:
  stringprocess: "^1.0.2"

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:stringprocess/stringprocess.dart';
        
Version Uploaded Documentation Archive
1.0.2 Apr 4, 2018 Go to the documentation of stringprocess 1.0.2 Download stringprocess 1.0.2 archive
1.0.1 Mar 31, 2018 Go to the documentation of stringprocess 1.0.1 Download stringprocess 1.0.1 archive
1.0.0 Mar 30, 2018 Go to the documentation of stringprocess 1.0.0 Download stringprocess 1.0.0 archive
0.0.9 Mar 26, 2018 Go to the documentation of stringprocess 0.0.9 Download stringprocess 0.0.9 archive
0.0.8 Sep 28, 2017 Go to the documentation of stringprocess 0.0.8 Download stringprocess 0.0.8 archive
0.0.7 Sep 19, 2017 Go to the documentation of stringprocess 0.0.7 Download stringprocess 0.0.7 archive
0.0.6 Aug 3, 2017 Go to the documentation of stringprocess 0.0.6 Download stringprocess 0.0.6 archive
0.0.5 Aug 2, 2017 Go to the documentation of stringprocess 0.0.5 Download stringprocess 0.0.5 archive
0.0.4 Jul 22, 2017 Go to the documentation of stringprocess 0.0.4 Download stringprocess 0.0.4 archive
0.0.3 Jul 16, 2017 Go to the documentation of stringprocess 0.0.3 Download stringprocess 0.0.3 archive

All 11 versions...

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]
64 / 100
Health:
Code health derived from static analysis. [more]
100 / 100
Maintenance:
Reflects how tidy and up-to-date the package is. [more]
100 / 100
Overall score:
Weighted score of the above. [more]
82
Learn more about scoring.

Platforms

Detected platforms: Flutter, web, other

No platform restriction found in primary library package:stringprocess/stringprocess.dart.

Dependencies

Package Constraint Resolved Available
Direct dependencies
Dart SDK >=1.20.1 <2.0.0
html_unescape ^0.1.5 0.1.5
markdown ^1.1.1 1.1.1
Dev dependencies
test ^0.12.0