func NewACLRules(r []storage.ACLRule) []ACLRule {
	var rules []ACLRule
	if l := len(r); l > 0 {
		rules = make([]ACLRule, l)
		for i, v := range r {
			rules[i] = NewACLRule(v)
		}
	}
	return rules
}
NewACLRules creates a new instance of ACLRule list from the storage counterpart
package v1alpha3
import (
	"time"
	"cloud.google.com/go/storage"
	metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
	xpv1 "github.com/crossplane/crossplane-runtime/apis/common/v1"
)
type ProjectTeam struct {
	ProjectNumber string `json:"projectNumber,omitempty"`
	Team string `json:"team,omitempty"`
}
func NewProjectTeam(pt *storage.ProjectTeam) *ProjectTeam {
	if pt == nil {
		return nil
	}
	return &ProjectTeam{
		ProjectNumber: pt.ProjectNumber,
		Team:          pt.Team,
	}
}
func CopyToProjectTeam(pt *ProjectTeam) *storage.ProjectTeam {
	if pt == nil {
		return nil
	}
	return &storage.ProjectTeam{
		ProjectNumber: pt.ProjectNumber,
		Team:          pt.Team,
	}
}
type ACLRule struct {
	Entity string `json:"entity,omitempty"`
	Role string `json:"role,omitempty"`
	EntityID string `json:"entityId,omitempty"`
	Domain string `json:"domain,omitempty"`
	Email string `json:"email,omitempty"`
	ProjectTeam *ProjectTeam `json:"projectTeam,omitempty"`
}
func NewACLRule(r storage.ACLRule) ACLRule {
	return ACLRule{
		Entity:      string(r.Entity),
		EntityID:    r.EntityID,
		Role:        string(r.Role),
		Domain:      r.Domain,
		Email:       r.Email,
		ProjectTeam: NewProjectTeam(r.ProjectTeam),
	}
}
func CopyToACLRule(ar ACLRule) storage.ACLRule {
	return storage.ACLRule{
		Entity:      storage.ACLEntity(ar.Entity),
		EntityID:    ar.EntityID,
		Role:        storage.ACLRole(ar.Role),
		Domain:      ar.Domain,
		Email:       ar.Email,
		ProjectTeam: CopyToProjectTeam(ar.ProjectTeam),
	}
}