1 // Copyright 2004-2007 Castle Project - http://www.castleproject.org/
3 // Licensed under the Apache License, Version 2.0 (the "License");
4 // you may not use this file except in compliance with the License.
5 // You may obtain a copy of the License at
7 // http://www.apache.org/licenses/LICENSE-2.0
9 // Unless required by applicable law or agreed to in writing, software
10 // distributed under the License is distributed on an "AS IS" BASIS,
11 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 // See the License for the specific language governing permissions and
13 // limitations under the License.
15 namespace Castle
.MonoRail
.Framework
20 /// Enum to identify a http verb
25 /// The GET method means retrieve whatever information is identified by the Request-URI.
27 /// The convention has been established that the GET method SHOULD
28 /// NOT have the significance of taking an action other than retrieval.
33 /// The POST method is used to request that the origin server accept the entity
34 /// enclosed in the request as a new subordinate of the resource identified by the
35 /// Request-URI in the Request-Line.
37 /// The convention has been established that the POST method will
38 /// take an action other than just retrieval.
45 /// Decorates an action with a restriction to the HTTP method
46 /// that is allowed to request it.
48 [AttributeUsage(AttributeTargets
.Method
), Serializable
]
49 public class AccessibleThroughAttribute
: Attribute
51 private readonly Verb verb
;
54 /// Constructs a AccessibleThroughAttribute with
55 /// the specified <paramref name="verb"/>.
57 /// <param name="verb">The <see cref="Verb"/> to allow for this action.</param>
58 public AccessibleThroughAttribute(Verb verb
)
64 /// The Verb to allow.