// IdentityFilterByID is a gorm filter for Identity ID.
550407
func IdentityFilterByID(identityID uuid.UUID) func(db *gorm.DB) *gorm.DB {
	return func(db *gorm.DB) *gorm.DB {
		return db.Where("id = ?", identityID)
	}
}
314109
func ExternalTokenFilterByProviderID(providerID uuid.UUID) func(db *gorm.DB) *gorm.DB {
	return func(db *gorm.DB) *gorm.DB {
		return db.Where("provider_id = ?", providerID)
	}
}
1353904
func (s *GetCredentialsForIdentityInput) SetIdentityId(v string) *GetCredentialsForIdentityInput {
	s.IdentityId = &v
	return s
}
254171
func (s *GetOpenIdTokenInput) SetIdentityId(v string) *GetOpenIdTokenInput {
	s.IdentityId = &v
	return s
}
116094
func (s *UnlinkIdentityInput) SetIdentityId(v string) *UnlinkIdentityInput {
	s.IdentityId = &v
	return s
}
166236
func (s *SubscribeToDatasetInput) SetIdentityId(v string) *SubscribeToDatasetInput {
	s.IdentityId = &v
	return s
}
59052
func filterForPrincipalSets(channel string, evaluator principalEvaluator, sets policies.PrincipalSets) identityFilter {
	return func(identity api.PeerIdentityType) bool {
		// Iterate over all principal sets and ensure each principal set
		// authorizes the identity.
		for _, principalSet := range sets {
			if !isIdentityAuthorizedByPrincipalSet(channel, evaluator, principalSet, identity) {
				return false
			}
		}
		return true
	}
}
235836
func (s *IdentityUsage) SetIdentityId(v string) *IdentityUsage {
	s.IdentityId = &v
	return s
}
950030
func (api *ProductLicenseAPI) FilterBy(key string, value interface{}) *ProductLicenseAPI {
	api.filterBy(key, value, false)
	return api
}
1211928
func identityRoleFilterByIdentityID(identityID uuid.UUID) func(db *gorm.DB) *gorm.DB {
	return func(db *gorm.DB) *gorm.DB {
		return db.Where("identity_id = ?", identityID)
	}
}
982635
func (s *LookupDeveloperIdentityOutput) SetIdentityId(v string) *LookupDeveloperIdentityOutput {
	s.IdentityId = &v
	return s
}
480738
func (s *UnlinkDeveloperIdentityInput) SetIdentityId(v string) *UnlinkDeveloperIdentityInput {
	s.IdentityId = &v
	return s
}
79800
func (s *GetIdOutput) SetIdentityId(v string) *GetIdOutput {
	s.IdentityId = &v
	return s
}
685715
func (s *RegisterDeviceInput) SetIdentityId(v string) *RegisterDeviceInput {
	s.IdentityId = &v
	return s
}
1357804
func (s *LookupDeveloperIdentityInput) SetIdentityId(v string) *LookupDeveloperIdentityInput {
	s.IdentityId = &v
	return s
}
228196
func IdentityFilterByRegistrationCompleted(registrationCompleted bool) func(db *gorm.DB) *gorm.DB {
	return func(db *gorm.DB) *gorm.DB {
		return db.Where("registration_completed = ?", registrationCompleted)
	}
}
1272933
func (u *User) Identifier() *msp.IdentityIdentifier {
	return &msp.IdentityIdentifier{MSPID: u.mspID, ID: u.id}
}