base

package module
v0.1.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 17, 2018 License: Apache-2.0 Imports: 2 Imported by: 241

README

moov-io/base

GoDoc Build Status Coverage Status Go Report Card Apbasee 2 licensed

Package github.com/moov-io/base implements core libraries used in multiple Moov projects. Refer to each projects documentation for more details.

Project Status

Note: This project is under active development and is not production ready, but we would appreciate feedback and contributions!

Getting Started

You can either clone down the code (git clone git@github.com:moov-io/base.git) or grab the modules into your cache (go get -u github.com/moov-io/base).

Getting Help

channel info
Project Documentation Our project documentation available online.
Google Group moov-users The Moov users Google group is for contributors other people contributing to the Moov project. You can join them without a google account by sending an email to moov-users+subscribe@googlegroups.com. After receiving the join-request message, you can simply reply to that to confirm the subscription.
Twitter @moov_io You can follow Moov.IO's Twitter feed to get updates on our project(s). You can also tweet us questions or just share blogs or stories.
GitHub Issue If you are able to reproduce an problem please open a GitHub Issue under the specific project that caused the error.
moov-io slack Join our slack channel to have an interactive discussion about the development of the project. Request an invite to the slack channel

Supported and Tested Platforms

  • 64-bit Linux (Ubuntu, Debian), macOS, and Windows
  • Rasberry Pi

Note: 32-bit platforms have known issues and is not supported.

Contributing

Yes please! Please review our Contributing guide and Code of Conduct to get started!

Note: This project uses Go Modules, which requires Go 1.11 or higher, but we ship the vendor directory in our repository.

License

Apbasee License 2.0 See LICENSE for details.

Documentation

Overview

Package base implements core libraries used in multiple Moov projects. Refer to each projects documentation for more details.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Time

type Time struct {
	time.Time
}

Time is an time.Time struct that encodes and decodes in ISO 8601.

ISO 8601 is usable by a large array of libraries whereas RFC 3339 support isn't often part of language standard libraries.

func NewTime

func NewTime(t time.Time) Time

NewTime wraps a time.Time value in Moov's base.Time struct. If you need the underlying time.Time value call .Time:

now := Now() fmt.Println(start.Sub(now.Time))

func Now

func Now() Time

Now returns a Time object with the current clock time set.

func (Time) Equal

func (t Time) Equal(other Time) bool

Equal compares two Time values. Time values are considered equal if they both truncate to the same year/month/day and hour/minute/second.

func (Time) MarshalJSON

func (t Time) MarshalJSON() ([]byte, error)

func (*Time) UnmarshalJSON

func (t *Time) UnmarshalJSON(data []byte) error

Directories

Path Synopsis
Package admin implements an http.Server which can be used for operations and monitoring tools.
Package admin implements an http.Server which can be used for operations and monitoring tools.
Package http implements a core suite of HTTP functions for use inside Moov.
Package http implements a core suite of HTTP functions for use inside Moov.
bind
Package bind returns well known HTTP local bind addresses for Moov services.
Package bind returns well known HTTP local bind addresses for Moov services.
lru
lru is a simple inmemory Recorder implementation.
lru is a simple inmemory Recorder implementation.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL