bufio

package
v0.0.0-...-a2a2cd2 Latest Latest
Warning

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

Go to latest
Published: Feb 5, 2023 License: MIT, MIT Imports: 3 Imported by: 0

Documentation

Overview

Package io provider buffered io to provide an efficient mecanism to accumulate data prior to physically persisting it.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ListToArrayOfCalibrationReadBatch

func ListToArrayOfCalibrationReadBatch(head *container.ImmutableList, size int) []apimodel.DayOfCalibrationReads

func ListToArrayOfExerciseBatch

func ListToArrayOfExerciseBatch(head *container.ImmutableList, size int) []apimodel.DayOfExercises

func ListToArrayOfGlucoseReadBatch

func ListToArrayOfGlucoseReadBatch(head *container.ImmutableList, size int) []apimodel.DayOfGlucoseReads

func ListToArrayOfInjectionBatch

func ListToArrayOfInjectionBatch(head *container.ImmutableList, size int) []apimodel.DayOfInjections

func ListToArrayOfMealBatch

func ListToArrayOfMealBatch(head *container.ImmutableList, size int) []apimodel.DayOfMeals

Types

type BufferedCalibrationBatchWriter

type BufferedCalibrationBatchWriter struct {
	// contains filtered or unexported fields
}

func NewCalibrationWriterSize

func NewCalibrationWriterSize(wr glukitio.CalibrationBatchWriter, flushSize int) *BufferedCalibrationBatchWriter

NewCalibrationWriterSize returns a new Writer whose Buffer has the specified size.

func (*BufferedCalibrationBatchWriter) Flush

Flush writes any buffered data to the underlying glukitio.Writer.

func (*BufferedCalibrationBatchWriter) WriteCalibrationBatch

WriteCalibration writes a single apimodel.DayOfCalibrationReads

func (*BufferedCalibrationBatchWriter) WriteCalibrationBatches

WriteCalibrationBatches writes the contents of p into the buffer. It returns the number of batches written. If nn < len(p), it also returns an error explaining why the write is short.

type BufferedExerciseBatchWriter

type BufferedExerciseBatchWriter struct {
	// contains filtered or unexported fields
}

func NewExerciseWriterSize

func NewExerciseWriterSize(wr glukitio.ExerciseBatchWriter, flushSize int) *BufferedExerciseBatchWriter

NewExerciseWriterSize returns a new Writer whose buffer has the specified size.

func (*BufferedExerciseBatchWriter) Flush

Flush writes any buffered data to the underlying glukitio.Writer.

func (*BufferedExerciseBatchWriter) WriteExerciseBatch

WriteExercise writes a single apimodel.DayOfExercises

func (*BufferedExerciseBatchWriter) WriteExerciseBatches

WriteExerciseBatches writes the contents of p into the buffer. It returns the number of batches written. If nn < len(p), it also returns an error explaining why the write is short.

type BufferedGlucoseReadBatchWriter

type BufferedGlucoseReadBatchWriter struct {
	// contains filtered or unexported fields
}

func NewGlucoseReadWriterSize

func NewGlucoseReadWriterSize(wr glukitio.GlucoseReadBatchWriter, flushSize int) *BufferedGlucoseReadBatchWriter

NewGlucoseReadWriterSize returns a new Writer whose Buffer has the specified size.

func (*BufferedGlucoseReadBatchWriter) Flush

Flush writes any Buffered data to the underlying glukitio.Writer.

func (*BufferedGlucoseReadBatchWriter) WriteGlucoseReadBatch

WriteGlucose writes a single apimodel.DayOfGlucoseReads

func (*BufferedGlucoseReadBatchWriter) WriteGlucoseReadBatches

WriteGlucoseReadBatches writes the contents of p into the Buffer. It returns the number of batches written. If nn < len(p), it also returns an error explaining why the write is short.

type BufferedInjectionBatchWriter

type BufferedInjectionBatchWriter struct {
	// contains filtered or unexported fields
}

func NewInjectionWriterSize

func NewInjectionWriterSize(wr glukitio.InjectionBatchWriter, flushSize int) *BufferedInjectionBatchWriter

NewInjectionWriterSize returns a new Writer whose buffer has the specified size.

func (*BufferedInjectionBatchWriter) Flush

Flush writes any buffered data to the underlying glukitio.Writer.

func (*BufferedInjectionBatchWriter) WriteInjectionBatch

WriteInjection writes a single apimodel.DayOfInjections

func (*BufferedInjectionBatchWriter) WriteInjectionBatches

WriteInjectionBatches writes the contents of p into the buffer. It returns the number of batches written. If nn < len(p), it also returns an error explaining why the write is short.

type BufferedMealBatchWriter

type BufferedMealBatchWriter struct {
	// contains filtered or unexported fields
}

func NewMealWriterSize

func NewMealWriterSize(wr glukitio.MealBatchWriter, flushSize int) *BufferedMealBatchWriter

NewMealWriterSize returns a new Writer whose buffer has the specified size.

func (*BufferedMealBatchWriter) Flush

Flush writes any buffered data to the underlying glukitio.Writer.

func (*BufferedMealBatchWriter) WriteMealBatch

WriteMeal writes a single apimodel.DayOfMeals

func (*BufferedMealBatchWriter) WriteMealBatches

WriteMealBatches writes the contents of p into the buffer. It returns the number of batches written. If nn < len(p), it also returns an error explaining why the write is short.

Jump to

Keyboard shortcuts

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