HttpServerBoxed 0.0.11 alpha
A simple http server for C# and .NET
Loading...
Searching...
No Matches
HSB.AssociatedFile Class Reference
Inheritance diagram for HSB.AssociatedFile:

Public Member Functions

 AssociatedFile (string filePath, HTTP_METHOD method=HTTP_METHOD.GET)
 
 AssociatedFile (string filePath, HTTP_METHOD[] methods)
 
 AssociatedFile (string filePath, string customMethod)
 
 AssociatedFile (string filePath, string[] customMethod)
 
bool MethodMatches (HTTP_METHOD method)
 
bool CustomMethodMatches (string method)
 

Properties

string FilePath [get]
 

Detailed Description

Definition at line 6 of file AssociatedFile.cs.

Constructor & Destructor Documentation

◆ AssociatedFile() [1/4]

HSB.AssociatedFile.AssociatedFile ( string  filePath,
HTTP_METHOD  method = HTTP_METHOD::GET 
)

Definition at line 12 of file AssociatedFile.cs.

13 {
14 this.filePath = filePath;
15 methods = [method];
16 customMethods = [];
17 }

◆ AssociatedFile() [2/4]

HSB.AssociatedFile.AssociatedFile ( string  filePath,
HTTP_METHOD[]  methods 
)

Definition at line 19 of file AssociatedFile.cs.

20 {
21 this.filePath = filePath;
22 this.methods = new(methods);
23 customMethods = [];
24 }

◆ AssociatedFile() [3/4]

HSB.AssociatedFile.AssociatedFile ( string  filePath,
string  customMethod 
)

Definition at line 25 of file AssociatedFile.cs.

26 {
27 this.filePath = filePath;
28 methods = [];
29 customMethods = [customMethod.ToUpper()];
30 }

◆ AssociatedFile() [4/4]

HSB.AssociatedFile.AssociatedFile ( string  filePath,
string[]  customMethod 
)

Definition at line 31 of file AssociatedFile.cs.

32 {
33 this.filePath = filePath;
34 methods = [];
35 customMethods = new(customMethod.Select(m => m.ToUpper()));
36 }

Member Function Documentation

◆ CustomMethodMatches()

bool HSB.AssociatedFile.CustomMethodMatches ( string  method)

Definition at line 45 of file AssociatedFile.cs.

46 {
47 return customMethods.Contains(method);
48 }

◆ MethodMatches()

bool HSB.AssociatedFile.MethodMatches ( HTTP_METHOD  method)

Definition at line 40 of file AssociatedFile.cs.

41 {
42 return methods.Contains(method);
43 }

Property Documentation

◆ FilePath

string HSB.AssociatedFile.FilePath
get

Definition at line 38 of file AssociatedFile.cs.


The documentation for this class was generated from the following file: