root / trunk / Pithos.Network / NoModificationInfo.cs @ 21141c06
History | View | Annotate | Download (1.3 kB)
1 |
// ----------------------------------------------------------------------- |
---|---|
2 |
// <copyright file="NoModificationInfo.cs" company="Microsoft"> |
3 |
// TODO: Update copyright text. |
4 |
// </copyright> |
5 |
// ----------------------------------------------------------------------- |
6 |
|
7 |
using System.Diagnostics.Contracts; |
8 |
using Pithos.Interfaces; |
9 |
|
10 |
namespace Pithos.Network |
11 |
{ |
12 |
using System; |
13 |
using System.Collections.Generic; |
14 |
using System.Linq; |
15 |
using System.Text; |
16 |
|
17 |
/// <summary> |
18 |
/// A special ObjectInfo that represents a NotModified HTTP Status (304) |
19 |
/// </summary> |
20 |
public class NoModificationInfo:ObjectInfo |
21 |
{ |
22 |
public NoModificationInfo(string account,Uri container) |
23 |
{ |
24 |
Contract.Requires(!String.IsNullOrWhiteSpace(account)); |
25 |
Contract.Requires(container!=null); |
26 |
Contract.Requires(!container.IsAbsoluteUri); |
27 |
|
28 |
Account = account; |
29 |
Container = container; |
30 |
} |
31 |
|
32 |
public NoModificationInfo(string account, Uri container,Uri folder) |
33 |
:this(account,container) |
34 |
{ |
35 |
Contract.Requires(folder!= null); |
36 |
Contract.Requires(!folder.IsAbsoluteUri); |
37 |
|
38 |
Name = new Uri(String.Format("{0}/",folder)); |
39 |
} |
40 |
|
41 |
} |
42 |
} |