v0.0.0-...-fd97e0e Latest Latest

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

Go to latest
Published: Mar 16, 2016 License: Apache-2.0, BSD-3-Clause Imports: 8 Imported by: 0



Package testpkg contains bound functions for testing the cgo-JNI interface. This is used in tests of golang.org/x/mobile/bind/java.



View Source
const (
	AString = "a string"
	AnInt   = 7
	ABool   = true
	AFloat  = 0.12345

	MinInt32               int32   = math.MinInt32
	MaxInt32               int32   = math.MaxInt32
	MinInt64                       = math.MinInt64
	MaxInt64                       = math.MaxInt64
	SmallestNonzeroFloat64         = math.SmallestNonzeroFloat64
	MaxFloat64                     = math.MaxFloat64
	SmallestNonzeroFloat32 float32 = math.SmallestNonzeroFloat64
	MaxFloat32             float32 = math.MaxFloat32
	Log2E                          = math.Log2E


View Source
var (
	StringVar    = "a string var"
	IntVar       = 77
	StructVar    = &S{name: "a struct var"}
	InterfaceVar I


func Add

func Add(x, y int) int

func AppendToString

func AppendToString(str string, someBytes []byte) []byte

func BytesAppend

func BytesAppend(a []byte, b []byte) []byte

func CallE

func CallE(i I) error

func CallF

func CallF(i I)

func CallV

func CallV(i I) int

func CallVE

func CallVE(i I) (int, error)

func Err

func Err(s string) error

func GC

func GC()

func GarbageCollect

func GarbageCollect()

func Hello

func Hello(r Receiver, name string)

func Keep

func Keep(i I)

func Negate

func Negate(x bool) bool

func NumSCollected

func NumSCollected() int

func ReadAsset

func ReadAsset() string

func StrDup

func StrDup(s string) string

func UnnamedParams

func UnnamedParams(_, _ int, p0 string) int


type I

type I interface {

	E() error
	V() int
	VE() (int, error)
	I() I
	S() *S
	StoString(*S) string

	String() string

func CallI

func CallI(i I) I

type Node

type Node struct {
	V    string
	Next *Node
	Err  error

func NewNode

func NewNode(name string) *Node

func (*Node) String

func (a *Node) String() string

type Receiver

type Receiver interface {
	Hello(message string)

type S

type S struct {
	// contains filtered or unexported fields

func CallS

func CallS(i I) *S

func New

func New() *S

func (*S) F

func (s *S) F()

func (*S) String

func (s *S) String() string

Jump to

Keyboard shortcuts

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