android

package
v0.0.0-...-016f308 Latest Latest
Warning

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

Go to latest
Published: Apr 27, 2015 License: Apache-2.0 Imports: 22 Imported by: 0

Documentation

Overview

Package android contains code specific to running the Camlistore client code as a child process on Android. This removes ugly API from the client package itself.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Dial

func Dial(network, addr string) (net.Conn, error)

func IsChild

func IsChild() bool

IsChild reports whether this process is running as an Android child process and should report its output in the form that the Android uploader app expects.

func NoteFileUploaded

func NoteFileUploaded(fullPath string, uploaded bool)

NoteFileUploaded is a hook for camput to report that a file was uploaded. TODO: move this to pkg/client/android probably.

func OnAndroid

func OnAndroid() bool

func PreExit

func PreExit()

func Printf

func Printf(format string, args ...interface{})

func TLSConfig

func TLSConfig() (*tls.Config, error)

Types

type StatsTransport

type StatsTransport struct {
	Rt http.RoundTripper
}

func (StatsTransport) RoundTrip

func (t StatsTransport) RoundTrip(req *http.Request) (res *http.Response, err error)

type StatusReceiver

type StatusReceiver struct {
	Sr   blobserver.StatReceiver
	Path string
}

androidStatusReceiver is a blobserver.StatReceiver wrapper that reports the full filename path and size of uploaded blobs. The android app wrapping camput watches stdout for this, for progress bars.

func (StatusReceiver) ReceiveBlob

func (asr StatusReceiver) ReceiveBlob(blob blob.Ref, source io.Reader) (blob.SizedRef, error)

func (StatusReceiver) StatBlobs

func (asr StatusReceiver) StatBlobs(dest chan<- blob.SizedRef, blobs []blob.Ref) error

Jump to

Keyboard shortcuts

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