pub struct GatedRequest {
pub resource: String,
pub content_creating: bool,
pub cost_hint: Option<u64>,
}Expand description
One request a source is about to send, as a RequestGate is asked about it.
Fields§
§resource: StringThe resource the request draws on, in QuotaReading::resource’s vocabulary; local
for a write a source makes to its own files.
content_creating: boolWhether the request creates content — an issue, a comment — which a backend may meter by a limit of its own (GitHub’s secondary content-creation limits).
cost_hint: Option<u64>What the source expects the request to cost against resource, when it can say.
Trait Implementations§
Source§impl Clone for GatedRequest
impl Clone for GatedRequest
Source§impl Debug for GatedRequest
impl Debug for GatedRequest
Source§impl<'de> Deserialize<'de> for GatedRequest
impl<'de> Deserialize<'de> for GatedRequest
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl Eq for GatedRequest
Source§impl JsonSchema for GatedRequest
impl JsonSchema for GatedRequest
Source§fn schema_id() -> Cow<'static, str>
fn schema_id() -> Cow<'static, str>
Returns a string that uniquely identifies the schema produced by this type. Read more
Source§fn json_schema(generator: &mut SchemaGenerator) -> Schema
fn json_schema(generator: &mut SchemaGenerator) -> Schema
Generates a JSON Schema for this type. Read more
Source§fn inline_schema() -> bool
fn inline_schema() -> bool
Whether JSON Schemas generated for this type should be included directly in parent schemas,
rather than being re-used where possible using the
$ref keyword. Read moreSource§impl PartialEq for GatedRequest
impl PartialEq for GatedRequest
Source§impl Serialize for GatedRequest
impl Serialize for GatedRequest
impl StructuralPartialEq for GatedRequest
Auto Trait Implementations§
impl Forget for GatedRequest
impl Freeze for GatedRequest
impl Move for GatedRequest
impl RefUnwindSafe for GatedRequest
impl Send for GatedRequest
impl Sync for GatedRequest
impl Unpin for GatedRequest
impl UnsafeUnpin for GatedRequest
impl UnwindSafe for GatedRequest
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more