itertor

package
v0.0.0-...-517d9f4 Latest Latest
Warning

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

Go to latest
Published: Sep 18, 2022 License: MIT Imports: 0 Imported by: 0

Documentation

Overview

Package itertor Time : 2022/8/17 09:44 Author : xushiyin contact : yuqingxushiyin@gmail.com

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Collection

type Collection interface {
	// contains filtered or unexported methods
}

type Iterator

type Iterator interface {
	HasNext() bool
	GetNext() *User
}

type User

type User struct {
	Name string
	Age  int
}

type UserCollection

type UserCollection struct {
	Users []*User
}

func (*UserCollection) CreateIterator

func (uc *UserCollection) CreateIterator() Iterator

type UserIterator

type UserIterator struct {
	Index int
	Users []*User
}

func (*UserIterator) GetNext

func (u *UserIterator) GetNext() *User

func (*UserIterator) HasNext

func (u *UserIterator) HasNext() bool

Jump to

Keyboard shortcuts

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