C# Класс CTCClassSchedule.Common.Html

Contains extension methods for the HtmlHelper class
Показать файл Открыть проект

Открытые методы

Метод Описание
CreditsValue ( this html, decimal credits ) : IHtmlString

Formats a Course credits for display to the user

This method removes decimal information if the value is a whole number.

CreditsValue ( this html, decimal credits, string nullMessage = null ) : IHtmlString

Formats a Course credits for display to the user

This method removes decimal information if the value is a whole number.

FormatWithSearchTerm ( this html, string searchTerm, string text ) : IHtmlString

Wrapper for Helpers.FormatWithSearchTerm which returns a Razor string.

Include ( this html, string fileAndPath ) : IHtmlString

Provides server-side include functionality

MVC does not support server-side includes on its own, so this method provides that functionality. It will include the file specified - including any nested server-side includes that are present in that file (and so on, etc.)

PageHelper ( this html ) : HtmlHelper

Provides access to the MVC HtmlHelper from Razor helpers.

See http://stackoverflow.com/questions/4710853/using-mvc-htmlhelper-extensions-from-razor-declarative-views

SectionCourseHeading ( this html, Course course, string credits = null, string searchTerm = null ) : IHtmlString
SectionCourseHeading ( this html, SectionWithSeats sec, string credits = null, string searchTerm = null ) : IHtmlString

Constructs course headings for blocks of sections on pages that display it.

SectionCourseHeading ( this html, string subject, string courseNumber, string courseTitle, string credits = null, string searchTerm = null ) : IHtmlString

Приватные методы

Метод Описание
ProcessIncludeFile ( string fileAndPath, System.Web.HttpServerUtilityBase server ) : string

TrimCreditsValue ( decimal credits ) : string

Описание методов

CreditsValue() публичный статический Метод

Formats a Course credits for display to the user
This method removes decimal information if the value is a whole number.
public static CreditsValue ( this html, decimal credits ) : IHtmlString
html this
credits decimal The credits value to format
Результат IHtmlString

CreditsValue() публичный статический Метод

Formats a Course credits for display to the user
This method removes decimal information if the value is a whole number.
public static CreditsValue ( this html, decimal credits, string nullMessage = null ) : IHtmlString
html this
credits decimal The credits value to format
nullMessage string Optional HTML to display if is null
Результат IHtmlString

FormatWithSearchTerm() публичный статический Метод

Wrapper for Helpers.FormatWithSearchTerm which returns a Razor string.
public static FormatWithSearchTerm ( this html, string searchTerm, string text ) : IHtmlString
html this
searchTerm string
text string
Результат IHtmlString

Include() публичный статический Метод

Provides server-side include functionality
MVC does not support server-side includes on its own, so this method provides that functionality. It will include the file specified - including any nested server-side includes that are present in that file (and so on, etc.)
public static Include ( this html, string fileAndPath ) : IHtmlString
html this
fileAndPath string
Результат IHtmlString

PageHelper() публичный статический Метод

Provides access to the MVC HtmlHelper from Razor helpers.
See http://stackoverflow.com/questions/4710853/using-mvc-htmlhelper-extensions-from-razor-declarative-views
public static PageHelper ( this html ) : HtmlHelper
html this
Результат HtmlHelper

SectionCourseHeading() публичный статический Метод

public static SectionCourseHeading ( this html, Course course, string credits = null, string searchTerm = null ) : IHtmlString
html this
course Course
credits string
searchTerm string
Результат IHtmlString

SectionCourseHeading() публичный статический Метод

Constructs course headings for blocks of sections on pages that display it.
public static SectionCourseHeading ( this html, SectionWithSeats sec, string credits = null, string searchTerm = null ) : IHtmlString
html this
sec CTCClassSchedule.Models.SectionWithSeats
credits string
searchTerm string
Результат IHtmlString

SectionCourseHeading() публичный статический Метод

public static SectionCourseHeading ( this html, string subject, string courseNumber, string courseTitle, string credits = null, string searchTerm = null ) : IHtmlString
html this
subject string
courseNumber string
courseTitle string
credits string
searchTerm string
Результат IHtmlString