Documentation ¶
Index ¶
- type ActualDifference
- type BusinessEntity
- func (this *BusinessEntity) GetActual(isState bool) map[string]interface{}
- func (this *BusinessEntity) GetBoolProperty(path string) bool
- func (this *BusinessEntity) GetFloatProperty(path string) float64
- func (this *BusinessEntity) GetInt64Property(path string) int64
- func (this *BusinessEntity) GetIntProperty(path string) int
- func (this *BusinessEntity) GetStringProperty(path string) string
- func (this *BusinessEntity) GetTimeProperty(path string) *time.Time
- func (this *BusinessEntity) GetUint64Property(path string) uint64
- func (this *BusinessEntity) GetUintProperty(path string) uint
- func (this *BusinessEntity) Update(actual map[string]interface{}, isState bool, isCheckActualId bool) map[uint64]map[string]error
- type BusinessEntityDifference
- type BusinessEntityService
- func (this *BusinessEntityService) AddRole(schemaName string, id uint64, parentId uint64, kind string, ...) (*BusinessEntity, *actual.Role)
- func (this *BusinessEntityService) Create(schemaName string, specId uint64, effectiveDate *time.Time) (*BusinessEntity, error)
- func (this *BusinessEntityService) Delete(schemaName string, id uint64) (int64, error)
- func (this *BusinessEntityService) Find(schemaName string, id uint64, path string, isState bool) (interface{}, string, bool)
- func (this *BusinessEntityService) Get(schemaName string, id uint64) *BusinessEntity
- func (this *BusinessEntityService) GetActual(schemaName string, id uint64, isState bool) map[string]interface{}
- func (this *BusinessEntityService) Load(schemaName string, id uint64) *BusinessEntity
- func (this *BusinessEntityService) LoadRole(schemaName string, id uint64, parentId uint64, kind string) (*BusinessEntity, []*actual.Role)
- func (this *BusinessEntityService) RemoveRole(schemaName string, id uint64, roleId uint64, path string) (*BusinessEntity, error)
- func (this *BusinessEntityService) Save(schemaName string, id uint64) (*BusinessEntity, error)
- func (this *BusinessEntityService) SetValue(data map[string]interface{}) (*BusinessEntity, error)
- func (this *BusinessEntityService) Update(actual map[string]interface{}) (*BusinessEntity, map[uint64]map[string]error)
- func (this *BusinessEntityService) Version(schemaName string, id uint64) (*BusinessEntity, error)
- type RuleMessage
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ActualDifference ¶
type BusinessEntity ¶
func (*BusinessEntity) GetActual ¶
func (this *BusinessEntity) GetActual(isState bool) map[string]interface{}
func (*BusinessEntity) GetBoolProperty ¶
func (this *BusinessEntity) GetBoolProperty(path string) bool
func (*BusinessEntity) GetFloatProperty ¶
func (this *BusinessEntity) GetFloatProperty(path string) float64
func (*BusinessEntity) GetInt64Property ¶
func (this *BusinessEntity) GetInt64Property(path string) int64
func (*BusinessEntity) GetIntProperty ¶
func (this *BusinessEntity) GetIntProperty(path string) int
func (*BusinessEntity) GetStringProperty ¶
func (this *BusinessEntity) GetStringProperty(path string) string
func (*BusinessEntity) GetTimeProperty ¶
func (this *BusinessEntity) GetTimeProperty(path string) *time.Time
func (*BusinessEntity) GetUint64Property ¶
func (this *BusinessEntity) GetUint64Property(path string) uint64
func (*BusinessEntity) GetUintProperty ¶
func (this *BusinessEntity) GetUintProperty(path string) uint
type BusinessEntityDifference ¶
type BusinessEntityDifference struct { PromptMessages map[string]map[string]*RuleMessage /** * @Fields compareResult : 所有的差异记录在一个多键值的映射中,包含角色和属性 * 角色的变化包含包含增加,修改,删除的角色(由BusinessEntity包裹), 在相同角色下的属性修改,变化的结果是一个列表, * 每一行代表一个修改的属性,每个差异代表属性的名称,旧值和新值 */ CompareRoleResult map[string][]*ActualDifference ComparePropertiesResult map[string][]*ActualDifference }
func (*BusinessEntityDifference) CompareRole ¶
func (this *BusinessEntityDifference) CompareRole(src *actual.Role, target *actual.Role)
type BusinessEntityService ¶
type BusinessEntityService struct { }
* 在BusinessEntity未被取出或者装载的情况下的操作
func GetBusinessEntityService ¶
func GetBusinessEntityService() *BusinessEntityService
func (*BusinessEntityService) AddRole ¶
func (this *BusinessEntityService) AddRole(schemaName string, id uint64, parentId uint64, kind string, values map[string]interface{}) (*BusinessEntity, *actual.Role)
func (*BusinessEntityService) Create ¶
func (this *BusinessEntityService) Create(schemaName string, specId uint64, effectiveDate *time.Time) (*BusinessEntity, error)
func (*BusinessEntityService) Delete ¶
func (this *BusinessEntityService) Delete(schemaName string, id uint64) (int64, error)
* 装载实例树,逐条删除,速度较慢
func (*BusinessEntityService) Get ¶
func (this *BusinessEntityService) Get(schemaName string, id uint64) *BusinessEntity
func (*BusinessEntityService) GetActual ¶
func (this *BusinessEntityService) GetActual(schemaName string, id uint64, isState bool) map[string]interface{}
func (*BusinessEntityService) Load ¶
func (this *BusinessEntityService) Load(schemaName string, id uint64) *BusinessEntity
func (*BusinessEntityService) LoadRole ¶
func (this *BusinessEntityService) LoadRole(schemaName string, id uint64, parentId uint64, kind string) (*BusinessEntity, []*actual.Role)
func (*BusinessEntityService) RemoveRole ¶
func (this *BusinessEntityService) RemoveRole(schemaName string, id uint64, roleId uint64, path string) (*BusinessEntity, error)
func (*BusinessEntityService) Save ¶
func (this *BusinessEntityService) Save(schemaName string, id uint64) (*BusinessEntity, error)
func (*BusinessEntityService) SetValue ¶
func (this *BusinessEntityService) SetValue(data map[string]interface{}) (*BusinessEntity, error)
* 根据映射中的id,parentId,path等字段获取角色和需要修改数据的子角色,并修改数据values映射
func (*BusinessEntityService) Update ¶
func (this *BusinessEntityService) Update(actual map[string]interface{}) (*BusinessEntity, map[uint64]map[string]error)
func (*BusinessEntityService) Version ¶
func (this *BusinessEntityService) Version(schemaName string, id uint64) (*BusinessEntity, error)
Click to show internal directories.
Click to hide internal directories.