Show / Hide Table of Contents

Class BaseStardogServer

Abstract implementation of a management connection to a Stardog server using the HTTP protocol.

Inheritance
object
BaseHttpConnector
BaseStardogServer
StardogV1Server
Implements
IAsyncStorageServer
IConfigurationSerializable
IStorageServer
IDisposable
Inherited Members
BaseHttpConnector.HttpClient
BaseHttpConnector.HttpClientHandler
BaseHttpConnector.SetProxy(string)
BaseHttpConnector.SetProxy(Uri)
BaseHttpConnector.Proxy
BaseHttpConnector.ClearProxy()
BaseHttpConnector.SetProxyCredentials(string, string)
BaseHttpConnector.SetProxyCredentials(string, string, string)
BaseHttpConnector.ProxyCredentials
BaseHttpConnector.ClearProxyCredentials()
BaseHttpConnector.Timeout
BaseHttpConnector.SerializeStandardConfig(INode, ConfigurationSerializationContext)
BaseHttpConnector.SetCredentials(string, string)
BaseHttpConnector.Dispose()
BaseHttpConnector.Dispose(bool)
object.Equals(object)
object.Equals(object, object)
object.GetHashCode()
object.GetType()
object.MemberwiseClone()
object.ReferenceEquals(object, object)
object.ToString()
Namespace: VDS.RDF.Storage.Management
Assembly: dotNetRdf.dll
Syntax
public abstract class BaseStardogServer : BaseHttpConnector, IAsyncStorageServer, IConfigurationSerializable, IStorageServer, IDisposable

Constructors

| Edit this page View Source

BaseStardogServer(string)

Creates a new connection to a Stardog Server.

Declaration
protected BaseStardogServer(string baseUri)
Parameters
Type Name Description
string baseUri

Base Uri of the Server.

| Edit this page View Source

BaseStardogServer(string, HttpClientHandler)

Creates a new connection to a Starddog server.

Declaration
protected BaseStardogServer(string baseUri, HttpClientHandler httpClientHandler)
Parameters
Type Name Description
string baseUri
HttpClientHandler httpClientHandler
| Edit this page View Source

BaseStardogServer(string, IWebProxy)

Creates a new connection to a Stardog Server.

Declaration
protected BaseStardogServer(string baseUri, IWebProxy proxy)
Parameters
Type Name Description
string baseUri

Base Uri of the Server.

IWebProxy proxy

Proxy Server.

| Edit this page View Source

BaseStardogServer(string, string, string)

Creates a new connection to a Stardog Server.

Declaration
protected BaseStardogServer(string baseUri, string username, string password)
Parameters
Type Name Description
string baseUri

Base Uri of the Server.

string username

Username.

string password

Password.

| Edit this page View Source

BaseStardogServer(string, string, string, IWebProxy)

Creates a new connection to a Stardog Server.

Declaration
protected BaseStardogServer(string baseUri, string username, string password, IWebProxy proxy)
Parameters
Type Name Description
string baseUri

Base Uri of the Server.

string username

Username.

string password

Password.

IWebProxy proxy

Proxy Server.

Fields

| Edit this page View Source

_adminUri

The URI of the admin API.

Declaration
protected readonly string _adminUri
Field Value
Type Description
string
| Edit this page View Source

_baseUri

The base URI of the Stardog server.

Declaration
protected readonly string _baseUri
Field Value
Type Description
string

Properties

| Edit this page View Source

HasCredentials

True if a user name and password are specified, false otherwise.

Declaration
protected bool HasCredentials { get; }
Property Value
Type Description
bool
| Edit this page View Source

IOBehaviour

Gets the IO Behaviour of the server.

Declaration
public virtual IOBehaviour IOBehaviour { get; }
Property Value
Type Description
IOBehaviour

Methods

| Edit this page View Source

CreateAdminRequest(string, string, HttpMethod, Dictionary<string, string>)

Create a request to the Stardog server's Admin API.

Declaration
protected virtual HttpRequestMessage CreateAdminRequest(string servicePath, string accept, HttpMethod method, Dictionary<string, string> requestParams)
Parameters
Type Name Description
string servicePath

The admin API service path.

string accept

Accept header content.

HttpMethod method

HTTP method to use.

Dictionary<string, string> requestParams

Additional request parameters.

Returns
Type Description
HttpRequestMessage
| Edit this page View Source

CreateAdminRequest(string, string, string, Dictionary<string, string>)

Create a request to the Stardog server's Admin API.

Declaration
[Obsolete("This method is obsolete and will be removed in a future release.")]
protected virtual HttpWebRequest CreateAdminRequest(string servicePath, string accept, string method, Dictionary<string, string> requestParams)
Parameters
Type Name Description
string servicePath

The admin API service path.

string accept

Accept header content.

string method

HTTP method to use.

Dictionary<string, string> requestParams

Additional request parameters.

Returns
Type Description
HttpWebRequest
| Edit this page View Source

CreateStore(IStoreTemplate)

Creates a new Store based off the given template.

Declaration
public virtual bool CreateStore(IStoreTemplate template)
Parameters
Type Name Description
IStoreTemplate template

Template.

Returns
Type Description
bool
Remarks

Templates must inherit from BaseStardogTemplate.

Uses some code based off on answers here to help do the multipart form data request.

| Edit this page View Source

CreateStore(IStoreTemplate, AsyncStorageCallback, object)

Creates a new store based on the given template.

Declaration
public virtual void CreateStore(IStoreTemplate template, AsyncStorageCallback callback, object state)
Parameters
Type Name Description
IStoreTemplate template

Template.

AsyncStorageCallback callback

Callback.

object state

State to pass to the callback.

Remarks

Template must inherit from BaseStardogTemplate.

| Edit this page View Source

CreateStoreAsync(IStoreTemplate, CancellationToken)

Creates a store asynchronously.

Declaration
public virtual Task<string> CreateStoreAsync(IStoreTemplate template, CancellationToken cancellationToken)
Parameters
Type Name Description
IStoreTemplate template

Template for the store to be created.

CancellationToken cancellationToken
Returns
Type Description
Task<string>
| Edit this page View Source

DeleteStore(string)

Deletes a Store with the given ID.

Declaration
public virtual void DeleteStore(string storeId)
Parameters
Type Name Description
string storeId

Store ID.

| Edit this page View Source

DeleteStore(string, AsyncStorageCallback, object)

Deletes a database from the server.

Declaration
public virtual void DeleteStore(string storeId, AsyncStorageCallback callback, object state)
Parameters
Type Name Description
string storeId

Store ID.

AsyncStorageCallback callback

Callback.

object state

State to pass to the callback.

| Edit this page View Source

DeleteStoreAsync(string, CancellationToken)

Deletes a store asynchronously.

Declaration
public Task DeleteStoreAsync(string storeId, CancellationToken cancellationToken)
Parameters
Type Name Description
string storeId

ID of the store to delete.

CancellationToken cancellationToken
Returns
Type Description
Task
| Edit this page View Source

GetAvailableTemplates(string)

Gets all available templates for creating a new Store.

Declaration
public virtual IEnumerable<IStoreTemplate> GetAvailableTemplates(string id)
Parameters
Type Name Description
string id

Store ID.

Returns
Type Description
IEnumerable<IStoreTemplate>
| Edit this page View Source

GetAvailableTemplates(string, AsyncStorageCallback, object)

Gets all available templates for creating a new Store.

Declaration
public virtual void GetAvailableTemplates(string id, AsyncStorageCallback callback, object state)
Parameters
Type Name Description
string id

Store ID.

AsyncStorageCallback callback

Callback.

object state

State to pass to the callback.

| Edit this page View Source

GetAvailableTemplatesAsync(string, CancellationToken)

Gets all available templates for creating a store with the given ID.

Declaration
public virtual Task<IEnumerable<IStoreTemplate>> GetAvailableTemplatesAsync(string id, CancellationToken cancellationToken)
Parameters
Type Name Description
string id

The store ID.

CancellationToken cancellationToken
Returns
Type Description
Task<IEnumerable<IStoreTemplate>>
| Edit this page View Source

GetDefaultTemplate(string)

Gets a default template for creating a new Store.

Declaration
public virtual IStoreTemplate GetDefaultTemplate(string id)
Parameters
Type Name Description
string id

Store ID.

Returns
Type Description
IStoreTemplate
| Edit this page View Source

GetDefaultTemplate(string, AsyncStorageCallback, object)

Gets a default template for creating a new Store.

Declaration
public virtual void GetDefaultTemplate(string id, AsyncStorageCallback callback, object state)
Parameters
Type Name Description
string id

Store ID.

AsyncStorageCallback callback

Callback.

object state

State to pass to the callback.

| Edit this page View Source

GetDefaultTemplateAsync(string, CancellationToken)

Gets a default template for creating a store with the given ID.

Declaration
public virtual Task<IStoreTemplate> GetDefaultTemplateAsync(string id, CancellationToken cancellationToken)
Parameters
Type Name Description
string id

The store ID.

CancellationToken cancellationToken
Returns
Type Description
Task<IStoreTemplate>
| Edit this page View Source

GetStore(string)

Gets a provider for the Store with the given ID.

Declaration
public abstract IStorageProvider GetStore(string storeId)
Parameters
Type Name Description
string storeId

Store ID.

Returns
Type Description
IStorageProvider
| Edit this page View Source

GetStore(string, AsyncStorageCallback, object)

Gets a database from the server.

Declaration
public abstract void GetStore(string storeId, AsyncStorageCallback callback, object state)
Parameters
Type Name Description
string storeId

Store ID.

AsyncStorageCallback callback

Callback.

object state

State to pass to the callback.

| Edit this page View Source

GetStoreAsync(string, CancellationToken)

Gets a store asynchronously.

Declaration
public abstract Task<IAsyncStorageProvider> GetStoreAsync(string storeId, CancellationToken cancellationToken)
Parameters
Type Name Description
string storeId

Store ID.

CancellationToken cancellationToken
Returns
Type Description
Task<IAsyncStorageProvider>
| Edit this page View Source

ListStores()

Lists the database available on the server.

Declaration
public virtual IEnumerable<string> ListStores()
Returns
Type Description
IEnumerable<string>
| Edit this page View Source

ListStores(AsyncStorageCallback, object)

Lists all databases available on the server.

Declaration
public virtual void ListStores(AsyncStorageCallback callback, object state)
Parameters
Type Name Description
AsyncStorageCallback callback

Callback.

object state

State to pass to the callback.

| Edit this page View Source

ListStoresAsync(CancellationToken)

Lists the available stores asynchronously.

Declaration
public Task<IEnumerable<string>> ListStoresAsync(CancellationToken cancellationToken)
Parameters
Type Name Description
CancellationToken cancellationToken
Returns
Type Description
Task<IEnumerable<string>>
| Edit this page View Source

SerializeConfiguration(ConfigurationSerializationContext)

Serializes the connection's configuration.

Declaration
public virtual void SerializeConfiguration(ConfigurationSerializationContext context)
Parameters
Type Name Description
ConfigurationSerializationContext context

Configuration Serialization Context.

Implements

IAsyncStorageServer
IConfigurationSerializable
IStorageServer
IDisposable

Extension Methods

Extensions.ToSafeString(object)
Extensions.AsEnumerable<T>(T)
  • Edit this page
  • View Source
In this article
  • Constructors
    • BaseStardogServer(string)
    • BaseStardogServer(string, HttpClientHandler)
    • BaseStardogServer(string, IWebProxy)
    • BaseStardogServer(string, string, string)
    • BaseStardogServer(string, string, string, IWebProxy)
  • Fields
    • _adminUri
    • _baseUri
  • Properties
    • HasCredentials
    • IOBehaviour
  • Methods
    • CreateAdminRequest(string, string, HttpMethod, Dictionary<string, string>)
    • CreateAdminRequest(string, string, string, Dictionary<string, string>)
    • CreateStore(IStoreTemplate)
    • CreateStore(IStoreTemplate, AsyncStorageCallback, object)
    • CreateStoreAsync(IStoreTemplate, CancellationToken)
    • DeleteStore(string)
    • DeleteStore(string, AsyncStorageCallback, object)
    • DeleteStoreAsync(string, CancellationToken)
    • GetAvailableTemplates(string)
    • GetAvailableTemplates(string, AsyncStorageCallback, object)
    • GetAvailableTemplatesAsync(string, CancellationToken)
    • GetDefaultTemplate(string)
    • GetDefaultTemplate(string, AsyncStorageCallback, object)
    • GetDefaultTemplateAsync(string, CancellationToken)
    • GetStore(string)
    • GetStore(string, AsyncStorageCallback, object)
    • GetStoreAsync(string, CancellationToken)
    • ListStores()
    • ListStores(AsyncStorageCallback, object)
    • ListStoresAsync(CancellationToken)
    • SerializeConfiguration(ConfigurationSerializationContext)
  • Implements
  • Extension Methods
Back to top Generated by DocFX