C# Класс APIWrapper, 3D-Repository

Overrides some of the functionality of the API_BASE to make compatible with serving from the web project Speciffically, skips HTTP Basic auth, and assumes that the website has delt with authorization. Takes a username in the constructor, in order to check permissions for later operations
Наследование: vwar.service.host._3DRAPI_Imp
Показать файл Открыть проект Примеры использования класса

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

Метод Описание
APIWrapper ( string inusername, HttpContext incontext ) : System

constructor

DoValidate ( Security type, vwarDAL co ) : bool

Overrides API base class validate, uses website user rather than HTTP Basic

GetUsername ( ) : string
SetResponseHeaders ( string type, int length, string disposition ) : void

Writes the headers for this transaction. Overrides base, using current context rather than WebOperationContext NOTE: For some reason this fails under the build in dev server, but runs correctly under IIS. Requires App pool to be in integrated mode

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

APIWrapper() публичный Метод

constructor
public APIWrapper ( string inusername, HttpContext incontext ) : System
inusername string The username of the currently authenticated user
incontext HttpContext The HTTP Context for this operation, used to write headers
Результат System

DoValidate() публичный Метод

Overrides API base class validate, uses website user rather than HTTP Basic
public DoValidate ( Security type, vwarDAL co ) : bool
type Security The transaction type to validate
co vwarDAL the content object to validate the operation on
Результат bool

GetUsername() публичный Метод

public GetUsername ( ) : string
Результат string

SetResponseHeaders() публичный Метод

Writes the headers for this transaction. Overrides base, using current context rather than WebOperationContext NOTE: For some reason this fails under the build in dev server, but runs correctly under IIS. Requires App pool to be in integrated mode
public SetResponseHeaders ( string type, int length, string disposition ) : void
type string Content Type
length int Content Lenght
disposition string Content Disposition
Результат void