Basic usage
Dependencies
Reference this library (dependency on Neo4jClient) and create a Neo4j GraphClient().
1: 2: 3: 4: 5: 6: 7: 8: 9: |
|
Define your model
Declare nodes & relationships in your model (by inheriting from INeo4jNode
or
INeo4jRelationship
interfaces).
Here we are defining users (UserNode
), households (HouseholdNode
) and
the IsResidentOf
relationship.
1: 2: 3: 4: 5: 6: 7: 8: 9: 10: 11: 12: |
|
Create user nodes
1: 2: 3: 4: |
|
Get all nodes with specific label
1: 2: 3: 4: 5: 6: |
|
Results
|
Get specific user
1: 2: 3: 4: 5: 6: |
|
Results
|
Create node and relate to it
Create a HouseholdNode
, mention that UserNode
Opwal has a IsResidentOf
relationship with it.
1: 2: 3: 4: 5: 6: 7: 8: 9: |
|
List all households where UserNode
Opwal resides:
1: 2: 3: 4: 5: 6: 7: 8: 9: 10: |
|
Results
|
namespace System
namespace Neo4jClient
namespace Neo4jClient.FsQuotations
val client : GraphClient
Full name: Tutorial.client
Full name: Tutorial.client
Multiple items
type GraphClient =
new : rootUri:Uri * httpClient:IHttpClient -> GraphClient + 2 overloads
member BatchEndpoint : Uri
member BeginTransaction : unit -> ITransaction + 1 overload
member CheckIndexExists : indexName:string * indexFor:IndexFor -> bool
member Connect : ?configuration:NeoServerConfiguration -> unit
member Create<'TNode> : node:'TNode * relationships:IEnumerable<IRelationshipAllowingParticipantNode<'TNode>> * indexEntries:IEnumerable<IndexEntry> -> NodeReference<'TNode>
member CreateIndex : indexName:string * config:IndexConfiguration * indexFor:IndexFor -> unit
member CreateRelationship<'TSourceNode, 'TRelationship> : sourceNodeReference:NodeReference<'TSourceNode> * relationship:'TRelationship -> RelationshipReference
member Cypher : ICypherFluentQuery
member CypherCapabilities : CypherCapabilities
...
Full name: Neo4jClient.GraphClient
--------------------
GraphClient(rootUri: Uri, httpClient: Execution.IHttpClient) : unit
GraphClient(rootUri: Uri, ?username: string, ?password: string) : unit
GraphClient(rootUri: Uri, expect100Continue: bool, useNagleAlgorithm: bool, ?username: string, ?password: string) : unit
type GraphClient =
new : rootUri:Uri * httpClient:IHttpClient -> GraphClient + 2 overloads
member BatchEndpoint : Uri
member BeginTransaction : unit -> ITransaction + 1 overload
member CheckIndexExists : indexName:string * indexFor:IndexFor -> bool
member Connect : ?configuration:NeoServerConfiguration -> unit
member Create<'TNode> : node:'TNode * relationships:IEnumerable<IRelationshipAllowingParticipantNode<'TNode>> * indexEntries:IEnumerable<IndexEntry> -> NodeReference<'TNode>
member CreateIndex : indexName:string * config:IndexConfiguration * indexFor:IndexFor -> unit
member CreateRelationship<'TSourceNode, 'TRelationship> : sourceNodeReference:NodeReference<'TSourceNode> * relationship:'TRelationship -> RelationshipReference
member Cypher : ICypherFluentQuery
member CypherCapabilities : CypherCapabilities
...
Full name: Neo4jClient.GraphClient
--------------------
GraphClient(rootUri: Uri, httpClient: Execution.IHttpClient) : unit
GraphClient(rootUri: Uri, ?username: string, ?password: string) : unit
GraphClient(rootUri: Uri, expect100Continue: bool, useNagleAlgorithm: bool, ?username: string, ?password: string) : unit
Multiple items
type Uri =
new : uriString:string -> Uri + 5 overloads
member AbsolutePath : string
member AbsoluteUri : string
member Authority : string
member DnsSafeHost : string
member Equals : comparand:obj -> bool
member Fragment : string
member GetComponents : components:UriComponents * format:UriFormat -> string
member GetHashCode : unit -> int
member GetLeftPart : part:UriPartial -> string
...
Full name: System.Uri
--------------------
Uri(uriString: string) : unit
Uri(uriString: string, uriKind: UriKind) : unit
Uri(baseUri: Uri, relativeUri: string) : unit
Uri(baseUri: Uri, relativeUri: Uri) : unit
type Uri =
new : uriString:string -> Uri + 5 overloads
member AbsolutePath : string
member AbsoluteUri : string
member Authority : string
member DnsSafeHost : string
member Equals : comparand:obj -> bool
member Fragment : string
member GetComponents : components:UriComponents * format:UriFormat -> string
member GetHashCode : unit -> int
member GetLeftPart : part:UriPartial -> string
...
Full name: System.Uri
--------------------
Uri(uriString: string) : unit
Uri(uriString: string, uriKind: UriKind) : unit
Uri(baseUri: Uri, relativeUri: string) : unit
Uri(baseUri: Uri, relativeUri: Uri) : unit
GraphClient.Connect(?configuration: NeoServerConfiguration) : unit
property GraphClient.Cypher: Cypher.ICypherFluentQuery
Cypher.ICypherFluentQuery.Match([<ParamArray>] matchText: string []) : Cypher.ICypherFluentQuery
Multiple items
type CLIMutableAttribute =
inherit Attribute
new : unit -> CLIMutableAttribute
Full name: Microsoft.FSharp.Core.CLIMutableAttribute
--------------------
new : unit -> CLIMutableAttribute
type CLIMutableAttribute =
inherit Attribute
new : unit -> CLIMutableAttribute
Full name: Microsoft.FSharp.Core.CLIMutableAttribute
--------------------
new : unit -> CLIMutableAttribute
type UserNode =
{FacebookId: string;}
interface INeo4jNode
Full name: Tutorial.UserNode
{FacebookId: string;}
interface INeo4jNode
Full name: Tutorial.UserNode
UserNode.FacebookId: string
Multiple items
val string : value:'T -> string
Full name: Microsoft.FSharp.Core.Operators.string
--------------------
type string = String
Full name: Microsoft.FSharp.Core.string
val string : value:'T -> string
Full name: Microsoft.FSharp.Core.Operators.string
--------------------
type string = String
Full name: Microsoft.FSharp.Core.string
type INeo4jNode
Full name: Neo4jClient.FsQuotations.INeo4jNode
Full name: Neo4jClient.FsQuotations.INeo4jNode
type HouseholdNode =
{Name: string;}
interface INeo4jNode
Full name: Tutorial.HouseholdNode
{Name: string;}
interface INeo4jNode
Full name: Tutorial.HouseholdNode
HouseholdNode.Name: string
Multiple items
type IsResidentOf =
interface INeo4jRelationship
new : unit -> IsResidentOf
Full name: Tutorial.IsResidentOf
--------------------
new : unit -> IsResidentOf
type IsResidentOf =
interface INeo4jRelationship
new : unit -> IsResidentOf
Full name: Tutorial.IsResidentOf
--------------------
new : unit -> IsResidentOf
type INeo4jRelationship
Full name: Neo4jClient.FsQuotations.INeo4jRelationship
Full name: Neo4jClient.FsQuotations.INeo4jRelationship
val id : string
val user : UserNode
val createNode : #INeo4jNode -> unit
Full name: Neo4jClient.FsQuotations.CypherQueryGrammar.createNode
Full name: Neo4jClient.FsQuotations.CypherQueryGrammar.createNode
val executeWriteQuery : cypher:Cypher.ICypherFluentQuery -> query:Quotations.Expr<unit> -> unit
Full name: Neo4jClient.FsQuotations.QuotationInterpreter.executeWriteQuery
Full name: Neo4jClient.FsQuotations.QuotationInterpreter.executeWriteQuery
val allUsers : UserNode list
Full name: Tutorial.allUsers
Full name: Tutorial.allUsers
val declareNode<'T (requires 'T :> INeo4jNode)> : #INeo4jNode
Full name: Neo4jClient.FsQuotations.CypherQueryGrammar.declareNode
Full name: Neo4jClient.FsQuotations.CypherQueryGrammar.declareNode
val matchNode : #INeo4jNode -> unit
Full name: Neo4jClient.FsQuotations.CypherQueryGrammar.matchNode
Full name: Neo4jClient.FsQuotations.CypherQueryGrammar.matchNode
val returnResults : 'T -> 'T
Full name: Neo4jClient.FsQuotations.CypherQueryGrammar.returnResults
Full name: Neo4jClient.FsQuotations.CypherQueryGrammar.returnResults
val executeReadQuery : cypher:Cypher.ICypherFluentQuery -> query:Quotations.Expr<'T> -> seq<'T>
Full name: Neo4jClient.FsQuotations.QuotationInterpreter.executeReadQuery
Full name: Neo4jClient.FsQuotations.QuotationInterpreter.executeReadQuery
module Seq
from Microsoft.FSharp.Collections
from Microsoft.FSharp.Collections
val toList : source:seq<'T> -> 'T list
Full name: Microsoft.FSharp.Collections.Seq.toList
Full name: Microsoft.FSharp.Collections.Seq.toList
val userTT : seq<UserNode>
Full name: Tutorial.userTT
Full name: Tutorial.userTT
val where : bool -> unit
Full name: Neo4jClient.FsQuotations.CypherQueryGrammar.where
Full name: Neo4jClient.FsQuotations.CypherQueryGrammar.where
val newHousehold : HouseholdNode
val createRightRelation : #INeo4jNode -> #INeo4jRelationship -> #INeo4jNode -> unit
Full name: Neo4jClient.FsQuotations.CypherQueryGrammar.createRightRelation
Full name: Neo4jClient.FsQuotations.CypherQueryGrammar.createRightRelation
val declareRelationship<'T (requires 'T :> INeo4jRelationship)> : #INeo4jRelationship
Full name: Neo4jClient.FsQuotations.CypherQueryGrammar.declareRelationship
Full name: Neo4jClient.FsQuotations.CypherQueryGrammar.declareRelationship
val opwalHouseholds : HouseholdNode list
Full name: Tutorial.opwalHouseholds
Full name: Tutorial.opwalHouseholds
val household : HouseholdNode
val matchRightRelation : #INeo4jNode -> #INeo4jRelationship -> #INeo4jNode -> unit
Full name: Neo4jClient.FsQuotations.CypherQueryGrammar.matchRightRelation
Full name: Neo4jClient.FsQuotations.CypherQueryGrammar.matchRightRelation