Skip to content

Commit

Permalink
Document current limitation with property values
Browse files Browse the repository at this point in the history
  • Loading branch information
fbiville committed Jan 27, 2023
1 parent b17318e commit 50a78df
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions neo4j/graph.go
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,8 @@ type PropertyValue interface {
// The property type T must adhere to neo4j.PropertyValue
// If the property does not exist, an error is returned
// If the property type does not match the type specification, an error is returned
//
// Note: due to the current limited generics support, any property array value other than byte array is typed as []any.
func GetProperty[T PropertyValue](entity Entity, key string) (T, error) {
rawValue, found := entity.GetProperties()[key]
if !found {
Expand Down

0 comments on commit 50a78df

Please sign in to comment.