func (storage *Storage) Volumes() ([]*Volume, error) {
	return ListReferencedVolumes(storage.Client, storage.volumes)
}
Volumes gets the volumes associated with this storage subsystem.
package redfish
import (
	"encoding/json"
	"reflect"
	"github.com/stmcginnis/gofish/common"
)
type CacheSummary struct {
	PersistentCacheSizeMiB int
	Status common.Status
	TotalCacheSizeMiB int
}
type Storage struct {
	common.Entity
	ODataContext string `json:"@odata.context"`
	ODataType string `json:"@odata.type"`
	Description string
	drives []string
	DrivesCount int `json:"Drives@odata.count"`
	Redundancy []Redundancy
	RedundancyCount int `json:"Redundancy@odata.count"`
	Status common.Status
	StorageControllers []StorageController
	StorageControllersCount int `json:"StorageControllers@odata.count"`
	volumes string
	enclosures []string
	EnclosuresCount int
	setEncryptionKeyTarget string
}
func (storage *Storage) UnmarshalJSON(b []byte) error {
	type temp Storage
	type links struct {
		Enclosures      common.Links
		EnclosuresCount int `json:"Enclosures@odata.count"`
	}
	type actions struct {
		SetEncryptionKey struct {
			Target string
		} `json:"#Storage.SetEncryptionKey"`
	}
	var t struct {
		temp
		Links   links
		Drives  common.Links
		Volumes common.Link
		Actions actions
	}
	err := json.Unmarshal(b, &t)
	if err != nil {
		return err
	}
	*storage = Storage(t.temp)
	storage.enclosures = t.Links.Enclosures.ToStrings()
	storage.EnclosuresCount = t.Links.EnclosuresCount
	storage.drives = t.Drives.ToStrings()
	storage.volumes = string(t.Volumes)
	storage.setEncryptionKeyTarget = t.Actions.SetEncryptionKey.Target
	return nil
}
func GetStorage(c common.Client, uri string) (*Storage, error) {
	resp, err := c.Get(uri)
	if err != nil {
		return nil, err
	}
	defer resp.Body.Close()
	var storage Storage
	err = json.NewDecoder(resp.Body).Decode(&storage)
	if err != nil {
		return nil, err
	}
	storage.SetClient(c)
	return &storage, nil
}
func ListReferencedStorages(c common.Client, link string) ([]*Storage, error) {  
	var result []*Storage
	if link == "" {
		return result, nil
	}
	links, err := common.GetCollection(c, link)
	if err != nil {
		return result, err
	}
	collectionError := common.NewCollectionError()
	for _, storageLink := range links.ItemLinks {
		storage, err := GetStorage(c, storageLink)
		if err != nil {
			collectionError.Failures[storageLink] = err
		} else {
			result = append(result, storage)
		}
	}
	if collectionError.Empty() {
		return result, nil
	}
	return result, collectionError
}
func (storage *Storage) Enclosures() ([]*Chassis, error) {
	var result []*Chassis
	collectionError := common.NewCollectionError()
	for _, chassisLink := range storage.enclosures {
		chassis, err := GetChassis(storage.Client, chassisLink)
		if err != nil {
			collectionError.Failures[chassisLink] = err
		} else {
			result = append(result, chassis)
		}
	}
	if collectionError.Empty() {
		return result, nil
	}
	return result, collectionError
}
func (storage *Storage) Drives() ([]*Drive, error) {
	var result []*Drive
	collectionError := common.NewCollectionError()
	for _, driveLink := range storage.drives {
		drive, err := GetDrive(storage.Client, driveLink)
		if err != nil {
			collectionError.Failures[driveLink] = err
		} else {
			result = append(result, drive)
		}
	}
	if collectionError.Empty() {
		return result, nil
	}
	return result, collectionError
}