func (resc *Resource) Context() (string, error) {
	if err := resc.init(); err != nil {
		return resc.context, err
	}
	return resc.context, nil
}
Context loads data from iCAT if needed, and returns the resources context attribute.
package gorods
import "C"
import (
	"fmt"
	"strconv"
	"strings"
	"time"
	"unsafe"
)
type Resource struct {
	name string
	typ           int
	comment       string
	createTime    time.Time
	modifyTime    time.Time
	id            int
	context       string
	zone          *Zone
	class         int
	children      string
	freeSpace     int
	info          string
	status        string
	parentStr     string
	net           string
	freeSpaceTime time.Time
	objCount      int
	storageType   string
	physPath      string
	parentSlice *Resources
	hasInit     bool
	con *Connection
}
type Resources []*Resource
func (rescs Resources) FindByName(name string) *Resource {
	for _, resc := range rescs {
		if resc.name == name {
			return resc
		}
	}
	return nil
}
func (rescs *Resources) Remove(index int) {
	*rescs = append((*rescs)[:index], (*rescs)[index+1:]...)
}
func initResource(name string, con *Connection) (*Resource, error) {
	resc := new(Resource)
	zne, er := con.LocalZone()
	if er != nil {
		return nil, er
	}
	resc.con = con
	resc.name = name
	resc.zone = zne
	return resc, nil
}
func (resc *Resource) init() error {
	if !resc.hasInit {
		if err := resc.RefreshInfo(); err != nil {
			return err
		}
		resc.hasInit = true
	}
	return nil
}
func (resc *Resource) Remove() bool {
	for n, p := range *resc.parentSlice {
		if p.name == resc.name {
			resc.parentSlice.Remove(n)
			return true
		}
	}
	return false
}
func (resc *Resource) String() string {
	return fmt.Sprintf("%v#%v", resc.Name(), resc.Zone().Name())
}
func (resc *Resource) Name() string {
	return resc.name
}
func (resc *Resource) Comment() (string, error) {
	if err := resc.init(); err != nil {
		return resc.comment, err
	}
	return resc.comment, nil
}
func (resc *Resource) CreateTime() (time.Time, error) {
	if err := resc.init(); err != nil {
		return resc.createTime, err
	}
	return resc.createTime, nil
}
func (resc *Resource) ModifyTime() (time.Time, error) {
	if err := resc.init(); err != nil {
		return resc.modifyTime, err
	}
	return resc.modifyTime, nil
}
func (resc *Resource) Id() (int, error) {
	if err := resc.init(); err != nil {
		return resc.id, err
	}
	return resc.id, nil
}
func (resc *Resource) Type() (int, error) {
	if err := resc.init(); err != nil {
		return resc.typ, err
	}
	return resc.typ, nil
}