Movatterモバイル変換


[0]ホーム

URL:


rickshaw

package
v2.26.5Latest Latest
Warning

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

Go to latest
Published: Nov 23, 2025 License:MITImports:13Imported by:0

Details

Repository

github.com/grokify/gocharts

Links

README

Rickshaw Example

This example creates a Rickshaw report using static, monthly data.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

funcRickshawExtensionsReport

func RickshawExtensionsReport(dataTemplateData)string

funcStreamRickshawExtensionsReport

func StreamRickshawExtensionsReport(qw422016 *qt422016.Writer, dataTemplateData)

funcWriteRickshawExtensionsReport

func WriteRickshawExtensionsReport(qq422016qtio422016.Writer, dataTemplateData)

Types

typeDataInfoJs

type DataInfoJs struct {Colorstring `json:"color,omitempty"`Data  []Item `json:"data"`Namestring `json:"name"`}

DataInfoJS is the series item to be sent to the Rickshaw extensions JS code.

typeItem

type Item struct {SeriesNamestring    `json:"-"`Timetime.Time `json:"-"`ValueXint64     `json:"x"`ValueYint64     `json:"y"`}

typeMonthData

type MonthData struct {SeriesNamestringMonthSstringYearSstringDt6intValueint64ValueSstring}

MonthData is the input value to be converted into Rickshaw items

func (*MonthData)Inflate

func (am *MonthData) Inflate()error

func (*MonthData)RickshawItem

func (am *MonthData) RickshawItem() (Item,error)

typeRickshawData

type RickshawData struct {SeriesMap map[string]SeriesMinXint64MaxXint64}

funcNewMonthlyRickshawDataFromSlotSeriesSet

func NewMonthlyRickshawDataFromSlotSeriesSet(setslot.SlotDataSeriesSet)RickshawData

funcNewRickshawData

func NewRickshawData()RickshawData

func (*RickshawData)AddItem

func (rd *RickshawData) AddItem(itemItem)

AddItem adds an item to the report

func (*RickshawData)Formatted

func (rd *RickshawData) Formatted() (RickshawDataFormatted,error)

Formatted returns formatted information ready for Rickshaw

func (*RickshawData)Inflate

func (rd *RickshawData) Inflate()

typeRickshawDataFormatted

type RickshawDataFormatted struct {SeriesNames   []stringSeriesData    [][]ItemFormattedData []DataInfoJs}

funcNewRickshawDataFormattedFromDateHistogram

func NewRickshawDataFormattedFromDateHistogram(timesetinterval.TimeSeriesSet)RickshawDataFormatted

typeSeries

type Series struct {ItemsMapX map[int64]ItemMinXint64MaxXint64}

func (*Series)Inflate

func (s *Series) Inflate()

typeTemplateData

type TemplateData struct {HeaderHTMLstringReportNamestringReportLinkstringRickshawURLstringRickshawDataFormattedRickshawDataFormattedItemTypestringIncludeDataTableboolIncludeDataTableTotalsbool}

func (*TemplateData)FormattedDataJSON

func (td *TemplateData) FormattedDataJSON() []byte

func (*TemplateData)TableData

func (td *TemplateData) TableData() ([]string, [][]string)

Source Files

View all Source files

Directories

PathSynopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f orF : Jump to
y orY : Canonical URL
go.dev uses cookies from Google to deliver and enhance the quality of its services and to analyze traffic.Learn more.

[8]ページ先頭

©2009-2025 Movatter.jp