C# Class Subtext.BlogML.BlogMLProvider

Provider for accessing data to implement BlogMl.
Inheritance: System.Configuration.Provider.ProviderBase, IBlogMLProvider
Afficher le fichier Open project: ayende/Subtext

Méthodes publiques

Méthode Description
CreateBlogPost ( BlogMLBlog blog, BlogMLPost post, string content, string>.IDictionary categoryIdMap ) : string

Creates a blog post and returns the id.

CreateCategories ( BlogMLBlog blog ) : string>.IDictionary

Creates categories from the blog ml.

CreatePostComment ( BlogMLComment bmlComment, string newPostId ) : void

Creates a comment in the system.

CreatePostTrackback ( BlogMLTrackback trackback, string newPostId ) : void

Creates a trackback for the post.

GetAllCategories ( string blogId ) : IList

Returns every blog category in the blog.

GetAttachmentDirectoryPath ( BlogMLAttachment attachment ) : string

The physical path to the attachment directory.

The attachment is passed in to give the blog engine the opportunity to use attachment specific directories (ex. based on mime type) should it choose.

GetAttachmentDirectoryUrl ( BlogMLAttachment attachment ) : string

The url to the attachment directory

The attachment is passed in to give the blog engine the opportunity to use attachment specific directories (ex. based on mime type) should it choose.

GetBlog ( string blogId ) : BlogMLBlog

Returns the information about the specified blog

GetBlogMlContext ( ) : IBlogMLContext

Returns the blog id from whichever context the provider happens to be running in.

GetBlogPosts ( string blogId, int pageIndex, int pageSize ) : IPagedCollection

Returns a page of fully hydrated blog posts. The blog posts allow the user of this method to navigate blog post categories, comments, etc...

ImportComplete ( ) : void
Initialize ( string name, System configValue ) : void

Initializes the provider with values from its configuration section in web.config.

The connection string can be initialized via the "ConnectionStringName" property or via the "ConnectionString" attribute.

If the "ConnectionStringName" is specified, the connection string is looked up in the ConnectionStrings section of web.config. If "ConnectionString" is specified, it overrides "ConnectionStringName" and is used instead.

Instance ( ) : IBlogMLProvider

Returns the default instance of this provider.

LogError ( string message, Exception e ) : void

Lets the provider decide how to log errors.

PreImport ( ) : void

Method called before an import begins. Allows the provider to initialize any state in the current blog.

SetBlogMlExtendedProperties ( BlogMLBlog extendedProperties ) : void

Sets the extended properties for the blog.

Method Details

CreateBlogPost() public abstract méthode

Creates a blog post and returns the id.
public abstract CreateBlogPost ( BlogMLBlog blog, BlogMLPost post, string content, string>.IDictionary categoryIdMap ) : string
blog BlogMLBlog
post BlogML.Xml.BlogMLPost
content string The rewritten content of the post.
categoryIdMap string>.IDictionary A dictionary used to map the blogml category id to the internal category id.
Résultat string

CreateCategories() public abstract méthode

Creates categories from the blog ml.
public abstract CreateCategories ( BlogMLBlog blog ) : string>.IDictionary
blog BlogMLBlog
Résultat string>.IDictionary

CreatePostComment() public abstract méthode

Creates a comment in the system.
public abstract CreatePostComment ( BlogMLComment bmlComment, string newPostId ) : void
bmlComment BlogML.Xml.BlogMLComment
newPostId string
Résultat void

CreatePostTrackback() public abstract méthode

Creates a trackback for the post.
public abstract CreatePostTrackback ( BlogMLTrackback trackback, string newPostId ) : void
trackback BlogML.Xml.BlogMLTrackback
newPostId string
Résultat void

GetAllCategories() public abstract méthode

Returns every blog category in the blog.
public abstract GetAllCategories ( string blogId ) : IList
blogId string
Résultat IList

GetAttachmentDirectoryPath() public abstract méthode

The physical path to the attachment directory.
The attachment is passed in to give the blog engine the opportunity to use attachment specific directories (ex. based on mime type) should it choose.
public abstract GetAttachmentDirectoryPath ( BlogMLAttachment attachment ) : string
attachment BlogML.Xml.BlogMLAttachment
Résultat string

GetAttachmentDirectoryUrl() public abstract méthode

The url to the attachment directory
The attachment is passed in to give the blog engine the opportunity to use attachment specific directories (ex. based on mime type) should it choose.
public abstract GetAttachmentDirectoryUrl ( BlogMLAttachment attachment ) : string
attachment BlogML.Xml.BlogMLAttachment
Résultat string

GetBlog() public abstract méthode

Returns the information about the specified blog
public abstract GetBlog ( string blogId ) : BlogMLBlog
blogId string
Résultat BlogMLBlog

GetBlogMlContext() public abstract méthode

Returns the blog id from whichever context the provider happens to be running in.
public abstract GetBlogMlContext ( ) : IBlogMLContext
Résultat IBlogMLContext

GetBlogPosts() public abstract méthode

Returns a page of fully hydrated blog posts. The blog posts allow the user of this method to navigate blog post categories, comments, etc...
public abstract GetBlogPosts ( string blogId, int pageIndex, int pageSize ) : IPagedCollection
blogId string
pageIndex int
pageSize int
Résultat IPagedCollection

ImportComplete() public abstract méthode

public abstract ImportComplete ( ) : void
Résultat void

Initialize() public méthode

Initializes the provider with values from its configuration section in web.config.

The connection string can be initialized via the "ConnectionStringName" property or via the "ConnectionString" attribute.

If the "ConnectionStringName" is specified, the connection string is looked up in the ConnectionStrings section of web.config. If "ConnectionString" is specified, it overrides "ConnectionStringName" and is used instead.

public Initialize ( string name, System configValue ) : void
name string The name.
configValue System The config value.
Résultat void

Instance() public static méthode

Returns the default instance of this provider.
public static Instance ( ) : IBlogMLProvider
Résultat IBlogMLProvider

LogError() public abstract méthode

Lets the provider decide how to log errors.
public abstract LogError ( string message, Exception e ) : void
message string
e System.Exception
Résultat void

PreImport() public abstract méthode

Method called before an import begins. Allows the provider to initialize any state in the current blog.
public abstract PreImport ( ) : void
Résultat void

SetBlogMlExtendedProperties() public abstract méthode

Sets the extended properties for the blog.
public abstract SetBlogMlExtendedProperties ( BlogMLBlog extendedProperties ) : void
extendedProperties BlogMLBlog
Résultat void