SemWeb.StaticSource

SemWeb : SemWeb Namespace
StaticSource Interface

This interface is implemented by SelectableSource classes that represent concrete data sources.

public interface StaticSource : , SelectableSource

#### Remarks

None.

## Members

### Properties

StatementCount [read-only] | int . Returns the number of statements in the data source.

### Methods

| GetBNodeFromPersistentId (string) : BNode Gets a BNode from a persistent identifier generated by SemWeb.StaticSource.GetPersistentBNodeId(SemWeb.BNode).
| GetEntities () : Entity[] Gets an array of all of the entities mentioned in the data source.
| GetMetas () : Entity[] Gets an array of all of the entities in the Meta position of statements in the data source.
| GetPersistentBNodeId (BNode) : string Creates a persistent identifier for a BNode which can be used with SemWeb.StaticSource.GetBNodeFromPersistentId(string).
| GetPredicates () : Entity[] Gets an array of all of the entities used in the predicate position of statements in the data source.

## Member Details

### GetBNodeFromPersistentId Method

public BNode GetBNodeFromPersistentId (string persistentId)

Gets a BNode from a persistent identifier generated by SemWeb.StaticSource.GetPersistentBNodeId(SemWeb.BNode).

#### Parameters

persistentId
  A persistent identifier generated by SemWeb.StaticSource.GetPersistentBNodeId(SemWeb.BNode).

#### Returns

The BNode corresponding to the identifier, or `null` if the identifier doesn't (or no longer) corresponds to a BNode.

#### Remarks

This method is never guarenteed to return a BNode, even if an identifier was previously returned for it.

### GetEntities Method

public Entity[] GetEntities ()

Gets an array of all of the entities mentioned in the data source.

#### Returns

An array of Entities. Each entity appears just once.

#### Remarks

None.

### GetMetas Method

public Entity[] GetMetas ()

Gets an array of all of the entities in the Meta position of statements in the data source.

#### Returns

An array of Entities. Each entity appears just once.

#### Remarks

None.

### GetPersistentBNodeId Method

public string GetPersistentBNodeId (BNode node)

Creates a persistent identifier for a BNode which can be used with SemWeb.StaticSource.GetBNodeFromPersistentId(string).

#### Parameters

node
  A BNode contained within this data source.

#### Returns

`null` if an identifier could not be assigned to this BNode, otherwise a globally-unique string identifier for this BNode.

#### Remarks

Use SemWeb.StaticSource.GetBNodeFromPersistentId(string) to get the BNode back at a future time.

### GetPredicates Method

public Entity[] GetPredicates ()

Gets an array of all of the entities used in the predicate position of statements in the data source.

#### Returns

An array of Entities. Each entity appears just once.

#### Remarks

None.

### StatementCount Property

public int StatementCount { get; }

Returns the number of statements in the data source.

#### Value

The number of statements in the data source.

#### Remarks

None.