From 9b05570408fb0dfe49eb9b019b052ab9cf84b46c Mon Sep 17 00:00:00 2001 From: SabaunT Date: Tue, 25 Jul 2023 18:29:14 +0000 Subject: [PATCH] deploy: 3bc11ace677dd0e114d6b8b78e46550adc863c54 --- .../code_storage/trait.CodeStorage.html | 32 ++++---- pr-2980/gear_common/enum.LockId.html | 6 +- pr-2980/gear_common/enum.Program.html | 6 +- pr-2980/gear_common/enum.ProgramState.html | 4 +- .../gear_common/event/enum.MessageEntry.html | 4 +- .../enum.MessageWaitedRuntimeReason.html | 2 +- .../gas_provider/enum.GasNodeId.html | 2 +- .../gear_common/gas_provider/enum.LockId.html | 6 +- .../struct.ResumeResult.html | 4 +- .../trait.PausedProgramStorage.html | 34 ++++----- .../program_storage/trait.ProgramStorage.html | 76 +++++++++---------- .../program_storage/type.MemoryMap.html | 2 +- .../scheduler/enum.ScheduledTask.html | 36 ++++----- .../scheduler/trait.TaskHandler.html | 40 +++++----- .../storage/struct.MailboxKeyGen.html | 2 +- .../storage/struct.QueueKeyGen.html | 2 +- .../storage/struct.WaitlistKeyGen.html | 2 +- pr-2980/gear_common/storage/trait.KeyFor.html | 2 +- pr-2980/gear_common/struct.ActiveProgram.html | 16 ++-- pr-2980/gear_common/trait.Origin.html | 2 +- .../implementors/core/convert/trait.From.js | 2 +- 21 files changed, 141 insertions(+), 141 deletions(-) diff --git a/pr-2980/gear_common/code_storage/trait.CodeStorage.html b/pr-2980/gear_common/code_storage/trait.CodeStorage.html index f63bb282c0f..4a00ed0d83e 100644 --- a/pr-2980/gear_common/code_storage/trait.CodeStorage.html +++ b/pr-2980/gear_common/code_storage/trait.CodeStorage.html @@ -1,25 +1,25 @@ CodeStorage in gear_common::code_storage - Rust
pub trait CodeStorage {
-    type InstrumentedCodeStorage: MapStorage<Key = CodeId, Value = InstrumentedCode>;
-    type InstrumentedLenStorage: MapStorage<Key = CodeId, Value = u32>;
-    type OriginalCodeStorage: MapStorage<Key = CodeId, Value = Vec<u8>>;
-    type MetadataStorage: MapStorage<Key = CodeId, Value = CodeMetadata>;
+    type InstrumentedCodeStorage: MapStorage<Key = CodeId, Value = InstrumentedCode>;
+    type InstrumentedLenStorage: MapStorage<Key = CodeId, Value = u32>;
+    type OriginalCodeStorage: MapStorage<Key = CodeId, Value = Vec<u8>>;
+    type MetadataStorage: MapStorage<Key = CodeId, Value = CodeMetadata>;
 
     // Provided methods
     fn reset() { ... }
     fn add_code(
-        code_and_id: CodeAndId,
+        code_and_id: CodeAndId,
         metadata: CodeMetadata
     ) -> Result<(), Error> { ... }
-    fn update_code(code_and_id: InstrumentedCodeAndId) { ... }
-    fn exists(code_id: CodeId) -> bool { ... }
-    fn remove_code(code_id: CodeId) -> bool { ... }
-    fn get_code(code_id: CodeId) -> Option<InstrumentedCode> { ... }
-    fn get_code_len(code_id: CodeId) -> Option<u32> { ... }
-    fn get_original_code(code_id: CodeId) -> Option<Vec<u8>> { ... }
-    fn get_metadata(code_id: CodeId) -> Option<CodeMetadata> { ... }
+    fn update_code(code_and_id: InstrumentedCodeAndId) { ... }
+    fn exists(code_id: CodeId) -> bool { ... }
+    fn remove_code(code_id: CodeId) -> bool { ... }
+    fn get_code(code_id: CodeId) -> Option<InstrumentedCode> { ... }
+    fn get_code_len(code_id: CodeId) -> Option<u32> { ... }
+    fn get_original_code(code_id: CodeId) -> Option<Vec<u8>> { ... }
+    fn get_metadata(code_id: CodeId) -> Option<CodeMetadata> { ... }
 }
Expand description

Trait to work with program binary codes in a storage.

-

Required Associated Types§

source

type InstrumentedCodeStorage: MapStorage<Key = CodeId, Value = InstrumentedCode>

source

type InstrumentedLenStorage: MapStorage<Key = CodeId, Value = u32>

source

type OriginalCodeStorage: MapStorage<Key = CodeId, Value = Vec<u8>>

source

type MetadataStorage: MapStorage<Key = CodeId, Value = CodeMetadata>

Provided Methods§

source

fn reset()

Attempt to remove all items from all the associated maps.

-
source

fn add_code(code_and_id: CodeAndId, metadata: CodeMetadata) -> Result<(), Error>

source

fn update_code(code_and_id: InstrumentedCodeAndId)

Update the corresponding code in the storage.

-
source

fn exists(code_id: CodeId) -> bool

source

fn remove_code(code_id: CodeId) -> bool

Returns true if the code associated with given id was removed.

+

Required Associated Types§

Provided Methods§

source

fn reset()

Attempt to remove all items from all the associated maps.

+
source

fn add_code(code_and_id: CodeAndId, metadata: CodeMetadata) -> Result<(), Error>

source

fn update_code(code_and_id: InstrumentedCodeAndId)

Update the corresponding code in the storage.

+
source

fn exists(code_id: CodeId) -> bool

source

fn remove_code(code_id: CodeId) -> bool

Returns true if the code associated with given id was removed.

If there is no code for the given id then false is returned.

-
source

fn get_code(code_id: CodeId) -> Option<InstrumentedCode>

source

fn get_code_len(code_id: CodeId) -> Option<u32>

source

fn get_original_code(code_id: CodeId) -> Option<Vec<u8>>

source

fn get_metadata(code_id: CodeId) -> Option<CodeMetadata>

Implementors§

\ No newline at end of file +
source

fn get_code(code_id: CodeId) -> Option<InstrumentedCode>

source

fn get_code_len(code_id: CodeId) -> Option<u32>

source

fn get_original_code(code_id: CodeId) -> Option<Vec<u8>>

source

fn get_metadata(code_id: CodeId) -> Option<CodeMetadata>

Implementors§

\ No newline at end of file diff --git a/pr-2980/gear_common/enum.LockId.html b/pr-2980/gear_common/enum.LockId.html index 812dd8bf6b9..f8d847fd52c 100644 --- a/pr-2980/gear_common/enum.LockId.html +++ b/pr-2980/gear_common/enum.LockId.html @@ -1,4 +1,4 @@ -LockId in gear_common - Rust

Trait Implementations§

§

impl Clone for LockId

§

fn clone(&self) -> LockId

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
§

impl Debug for LockId

§

fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

Formats the value using the given formatter. Read more
source§

impl<Balance> Index<LockId> for NodeLock<Balance>

§

type Output = Balance

The returned type after indexing.
source§

fn index(&self, index: LockId) -> &Self::Output

Performs the indexing (container[index]) operation. Read more
source§

impl<Balance> IndexMut<LockId> for NodeLock<Balance>

source§

fn index_mut(&mut self, index: LockId) -> &mut Self::Output

Performs the mutable indexing (container[index]) operation. Read more
§

impl PartialEq<LockId> for LockId

§

fn eq(&self, other: &LockId) -> bool

This method tests for self and other values to be equal, and is used +

Trait Implementations§

source§

impl Clone for LockId

source§

fn clone(&self) -> LockId

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for LockId

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

Formats the value using the given formatter. Read more
source§

impl<Balance> Index<LockId> for NodeLock<Balance>

§

type Output = Balance

The returned type after indexing.
source§

fn index(&self, index: LockId) -> &Self::Output

Performs the indexing (container[index]) operation. Read more
source§

impl<Balance> IndexMut<LockId> for NodeLock<Balance>

source§

fn index_mut(&mut self, index: LockId) -> &mut Self::Output

Performs the mutable indexing (container[index]) operation. Read more
source§

impl PartialEq<LockId> for LockId

source§

fn eq(&self, other: &LockId) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always -sufficient, and should not be overridden without very good reason.
§

impl Sequence for LockId

§

const CARDINALITY: usize = 4usize

Number of values of type Self. Read more
§

fn next(&self) -> Option<LockId>

Returns value following *self or None if this was the end. Read more
§

fn previous(&self) -> Option<LockId>

Returns value preceding *self or None if this was the beginning. Read more
§

fn first() -> Option<LockId>

Returns the first value of type Self. Read more
§

fn last() -> Option<LockId>

Returns the last value of type Self. Read more
source§

impl TryFrom<StorageType> for LockId

§

type Error = TryFromStorageTypeError

The type returned in the event of a conversion error.
source§

fn try_from(storage: StorageType) -> Result<Self, Self::Error>

Performs the conversion.
§

impl Copy for LockId

§

impl Eq for LockId

§

impl StructuralEq for LockId

§

impl StructuralPartialEq for LockId

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for Twhere +sufficient, and should not be overridden without very good reason.

source§

impl Sequence for LockId

source§

const CARDINALITY: usize = 4usize

Number of values of type Self. Read more
source§

fn next(&self) -> Option<LockId>

Returns value following *self or None if this was the end. Read more
source§

fn previous(&self) -> Option<LockId>

Returns value preceding *self or None if this was the beginning. Read more
source§

fn first() -> Option<LockId>

Returns the first value of type Self. Read more
source§

fn last() -> Option<LockId>

Returns the last value of type Self. Read more
source§

impl TryFrom<StorageType> for LockId

§

type Error = TryFromStorageTypeError

The type returned in the event of a conversion error.
source§

fn try_from(storage: StorageType) -> Result<Self, Self::Error>

Performs the conversion.
source§

impl Copy for LockId

source§

impl Eq for LockId

source§

impl StructuralEq for LockId

source§

impl StructuralPartialEq for LockId

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for Twhere T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for Twhere T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for Twhere T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
§

impl<T> CheckedConversion for T

§

fn checked_from<T>(t: T) -> Option<Self>where diff --git a/pr-2980/gear_common/enum.Program.html b/pr-2980/gear_common/enum.Program.html index c5d8ffe80ac..93cdaffce56 100644 --- a/pr-2980/gear_common/enum.Program.html +++ b/pr-2980/gear_common/enum.Program.html @@ -1,8 +1,8 @@ Program in gear_common - Rust

Enum gear_common::Program

source ·
pub enum Program<BlockNumber: Copy + Saturating> {
     Active(ActiveProgram<BlockNumber>),
-    Exited(ProgramId),
-    Terminated(ProgramId),
-}

Variants§

§

Active(ActiveProgram<BlockNumber>)

§

Exited(ProgramId)

§

Terminated(ProgramId)

Implementations§

source§

impl<BlockNumber: Copy + Saturating> Program<BlockNumber>

source

pub fn is_active(&self) -> bool

source

pub fn is_exited(&self) -> bool

source

pub fn is_terminated(&self) -> bool

source

pub fn is_initialized(&self) -> bool

source

pub fn is_uninitialized(&self) -> Option<MessageId>

Trait Implementations§

source§

impl<BlockNumber: Clone + Copy + Saturating> Clone for Program<BlockNumber>

source§

fn clone(&self) -> Program<BlockNumber>

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl<BlockNumber: Debug + Copy + Saturating> Debug for Program<BlockNumber>

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<BlockNumber: Copy + Saturating> Decode for Program<BlockNumber>where + Exited(ProgramId), + Terminated(ProgramId), +}

Variants§

§

Active(ActiveProgram<BlockNumber>)

§

Exited(ProgramId)

§

Terminated(ProgramId)

Implementations§

source§

impl<BlockNumber: Copy + Saturating> Program<BlockNumber>

source

pub fn is_active(&self) -> bool

source

pub fn is_exited(&self) -> bool

source

pub fn is_terminated(&self) -> bool

source

pub fn is_initialized(&self) -> bool

source

pub fn is_uninitialized(&self) -> Option<MessageId>

Trait Implementations§

source§

impl<BlockNumber: Clone + Copy + Saturating> Clone for Program<BlockNumber>

source§

fn clone(&self) -> Program<BlockNumber>

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl<BlockNumber: Debug + Copy + Saturating> Debug for Program<BlockNumber>

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<BlockNumber: Copy + Saturating> Decode for Program<BlockNumber>where ActiveProgram<BlockNumber>: Decode,

source§

fn decode<__CodecInputEdqy: Input>( __codec_input_edqy: &mut __CodecInputEdqy ) -> Result<Self, Error>

Attempt to deserialise the value from input.
§

fn decode_into<I>( diff --git a/pr-2980/gear_common/enum.ProgramState.html b/pr-2980/gear_common/enum.ProgramState.html index bfc9c0ceb80..acfb505c593 100644 --- a/pr-2980/gear_common/enum.ProgramState.html +++ b/pr-2980/gear_common/enum.ProgramState.html @@ -1,10 +1,10 @@ ProgramState in gear_common - Rust
pub enum ProgramState {
     Uninitialized {
-        message_id: MessageId,
+        message_id: MessageId,
     },
     Initialized,
 }
Expand description

Enumeration contains variants for program state.

-

Variants§

§

Uninitialized

Fields

§message_id: MessageId

init method of a program has not yet finished its execution so +

Variants§

§

Uninitialized

Fields

§message_id: MessageId

init method of a program has not yet finished its execution so the program is not considered as initialized. All messages to such a program go to the wait list. message_id contains identifier of the initialization message.

diff --git a/pr-2980/gear_common/event/enum.MessageEntry.html b/pr-2980/gear_common/event/enum.MessageEntry.html index 60d8b145c4f..a0e4f16eb49 100644 --- a/pr-2980/gear_common/event/enum.MessageEntry.html +++ b/pr-2980/gear_common/event/enum.MessageEntry.html @@ -1,14 +1,14 @@ MessageEntry in gear_common::event - Rust
pub enum MessageEntry {
     Init,
     Handle,
-    Reply(MessageId),
+    Reply(MessageId),
     Signal,
 }
Expand description

Programs entry for messages.

Same as gear_core::message::DispatchKind, but with additional info about reply.

Variants§

§

Init

Init entry point.

§

Handle

Handle entry point.

-
§

Reply(MessageId)

Handle reply entry point.

+
§

Reply(MessageId)

Handle reply entry point.

§

Signal

System signal entry point.

Trait Implementations§

source§

impl Clone for MessageEntry

source§

fn clone(&self) -> MessageEntry

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for MessageEntry

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Decode for MessageEntry

source§

fn decode<__CodecInputEdqy: Input>( __codec_input_edqy: &mut __CodecInputEdqy diff --git a/pr-2980/gear_common/event/enum.MessageWaitedRuntimeReason.html b/pr-2980/gear_common/event/enum.MessageWaitedRuntimeReason.html index 2bc76cb7494..82cafe46c8c 100644 --- a/pr-2980/gear_common/event/enum.MessageWaitedRuntimeReason.html +++ b/pr-2980/gear_common/event/enum.MessageWaitedRuntimeReason.html @@ -21,7 +21,7 @@ &self, __codec_dest_edqy: &mut __CodecOutputEdqy )

Convert self to a slice and append it to the destination.
§

fn encode(&self) -> Vec<u8, Global>

Convert self to an owned vector.
§

fn using_encoded<R, F>(&self, f: F) -> Rwhere - F: FnOnce(&[u8]) -> R,

Convert self to a slice and then invoke the given closure with it.
§

fn encoded_size(&self) -> usize

Calculates the encoded size. Read more
source§

impl From<MessageWaitedType> for MessageWaitedRuntimeReason

source§

fn from(src: MessageWaitedType) -> Self

Converts to this type from the input type.
source§

impl PartialEq<MessageWaitedRuntimeReason> for MessageWaitedRuntimeReason

source§

fn eq(&self, other: &MessageWaitedRuntimeReason) -> bool

This method tests for self and other values to be equal, and is used + F: FnOnce(&[u8]) -> R,

Convert self to a slice and then invoke the given closure with it.
§

fn encoded_size(&self) -> usize

Calculates the encoded size. Read more

source§

impl From<MessageWaitedType> for MessageWaitedRuntimeReason

source§

fn from(src: MessageWaitedType) -> Self

Converts to this type from the input type.
source§

impl PartialEq<MessageWaitedRuntimeReason> for MessageWaitedRuntimeReason

source§

fn eq(&self, other: &MessageWaitedRuntimeReason) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl RuntimeReason for MessageWaitedRuntimeReason

source§

fn into_reason<S: SystemReason>(self) -> Reason<Self, S>

Converter into composite reason type: not only runtime, but system also.
source§

impl TypeInfo for MessageWaitedRuntimeReason

§

type Identity = MessageWaitedRuntimeReason

The type identifying for which type info is provided. Read more
source§

fn type_info() -> Type

Returns the static type identifier for Self.
source§

impl EncodeLike<MessageWaitedRuntimeReason> for MessageWaitedRuntimeReason

source§

impl Eq for MessageWaitedRuntimeReason

source§

impl StructuralEq for MessageWaitedRuntimeReason

source§

impl StructuralPartialEq for MessageWaitedRuntimeReason

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for Twhere T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for Twhere diff --git a/pr-2980/gear_common/gas_provider/enum.GasNodeId.html b/pr-2980/gear_common/gas_provider/enum.GasNodeId.html index 91a973ef1fc..2771a0407ec 100644 --- a/pr-2980/gear_common/gas_provider/enum.GasNodeId.html +++ b/pr-2980/gear_common/gas_provider/enum.GasNodeId.html @@ -19,7 +19,7 @@ &self, __codec_dest_edqy: &mut __CodecOutputEdqy )

Convert self to a slice and append it to the destination.
§

fn encode(&self) -> Vec<u8, Global>

Convert self to an owned vector.
§

fn using_encoded<R, F>(&self, f: F) -> Rwhere - F: FnOnce(&[u8]) -> R,

Convert self to a slice and then invoke the given closure with it.
§

fn encoded_size(&self) -> usize

Calculates the encoded size. Read more
source§

impl<U> From<MessageId> for GasNodeId<MessageId, U>

source§

fn from(id: MessageId) -> Self

Converts to this type from the input type.
source§

impl<T> From<ReservationId> for GasNodeId<T, ReservationId>

source§

fn from(id: ReservationId) -> Self

Converts to this type from the input type.
source§

impl<T: Hash, U: Hash> Hash for GasNodeId<T, U>

source§

fn hash<__H: Hasher>(&self, state: &mut __H)

Feeds this value into the given Hasher. Read more
1.3.0 · source§

fn hash_slice<H>(data: &[Self], state: &mut H)where + F: FnOnce(&[u8]) -> R,

Convert self to a slice and then invoke the given closure with it.
§

fn encoded_size(&self) -> usize

Calculates the encoded size. Read more
source§

impl<U> From<MessageId> for GasNodeId<MessageId, U>

source§

fn from(id: MessageId) -> Self

Converts to this type from the input type.
source§

impl<T> From<ReservationId> for GasNodeId<T, ReservationId>

source§

fn from(id: ReservationId) -> Self

Converts to this type from the input type.
source§

impl<T: Hash, U: Hash> Hash for GasNodeId<T, U>

source§

fn hash<__H: Hasher>(&self, state: &mut __H)

Feeds this value into the given Hasher. Read more
1.3.0 · source§

fn hash_slice<H>(data: &[Self], state: &mut H)where H: Hasher, Self: Sized,

Feeds a slice of this type into the given Hasher. Read more
source§

impl<T: Ord, U: Ord> Ord for GasNodeId<T, U>

source§

fn cmp(&self, other: &GasNodeId<T, U>) -> Ordering

This method returns an Ordering between self and other. Read more
1.21.0 · source§

fn max(self, other: Self) -> Selfwhere Self: Sized,

Compares and returns the maximum of two values. Read more
1.21.0 · source§

fn min(self, other: Self) -> Selfwhere diff --git a/pr-2980/gear_common/gas_provider/enum.LockId.html b/pr-2980/gear_common/gas_provider/enum.LockId.html index ffd75044524..3abe6e7741a 100644 --- a/pr-2980/gear_common/gas_provider/enum.LockId.html +++ b/pr-2980/gear_common/gas_provider/enum.LockId.html @@ -1,4 +1,4 @@ -LockId in gear_common::gas_provider - Rust

Trait Implementations§

§

impl Clone for LockId

§

fn clone(&self) -> LockId

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
§

impl Debug for LockId

§

fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

Formats the value using the given formatter. Read more
source§

impl<Balance> Index<LockId> for NodeLock<Balance>

§

type Output = Balance

The returned type after indexing.
source§

fn index(&self, index: LockId) -> &Self::Output

Performs the indexing (container[index]) operation. Read more
source§

impl<Balance> IndexMut<LockId> for NodeLock<Balance>

source§

fn index_mut(&mut self, index: LockId) -> &mut Self::Output

Performs the mutable indexing (container[index]) operation. Read more
§

impl PartialEq<LockId> for LockId

§

fn eq(&self, other: &LockId) -> bool

This method tests for self and other values to be equal, and is used +

Trait Implementations§

source§

impl Clone for LockId

source§

fn clone(&self) -> LockId

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for LockId

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

Formats the value using the given formatter. Read more
source§

impl<Balance> Index<LockId> for NodeLock<Balance>

§

type Output = Balance

The returned type after indexing.
source§

fn index(&self, index: LockId) -> &Self::Output

Performs the indexing (container[index]) operation. Read more
source§

impl<Balance> IndexMut<LockId> for NodeLock<Balance>

source§

fn index_mut(&mut self, index: LockId) -> &mut Self::Output

Performs the mutable indexing (container[index]) operation. Read more
source§

impl PartialEq<LockId> for LockId

source§

fn eq(&self, other: &LockId) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always -sufficient, and should not be overridden without very good reason.
§

impl Sequence for LockId

§

const CARDINALITY: usize = 4usize

Number of values of type Self. Read more
§

fn next(&self) -> Option<LockId>

Returns value following *self or None if this was the end. Read more
§

fn previous(&self) -> Option<LockId>

Returns value preceding *self or None if this was the beginning. Read more
§

fn first() -> Option<LockId>

Returns the first value of type Self. Read more
§

fn last() -> Option<LockId>

Returns the last value of type Self. Read more
source§

impl TryFrom<StorageType> for LockId

§

type Error = TryFromStorageTypeError

The type returned in the event of a conversion error.
source§

fn try_from(storage: StorageType) -> Result<Self, Self::Error>

Performs the conversion.
§

impl Copy for LockId

§

impl Eq for LockId

§

impl StructuralEq for LockId

§

impl StructuralPartialEq for LockId

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for Twhere +sufficient, and should not be overridden without very good reason.

source§

impl Sequence for LockId

source§

const CARDINALITY: usize = 4usize

Number of values of type Self. Read more
source§

fn next(&self) -> Option<LockId>

Returns value following *self or None if this was the end. Read more
source§

fn previous(&self) -> Option<LockId>

Returns value preceding *self or None if this was the beginning. Read more
source§

fn first() -> Option<LockId>

Returns the first value of type Self. Read more
source§

fn last() -> Option<LockId>

Returns the last value of type Self. Read more
source§

impl TryFrom<StorageType> for LockId

§

type Error = TryFromStorageTypeError

The type returned in the event of a conversion error.
source§

fn try_from(storage: StorageType) -> Result<Self, Self::Error>

Performs the conversion.
source§

impl Copy for LockId

source§

impl Eq for LockId

source§

impl StructuralEq for LockId

source§

impl StructuralPartialEq for LockId

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for Twhere T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for Twhere T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for Twhere T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
§

impl<T> CheckedConversion for T

§

fn checked_from<T>(t: T) -> Option<Self>where diff --git a/pr-2980/gear_common/paused_program_storage/struct.ResumeResult.html b/pr-2980/gear_common/paused_program_storage/struct.ResumeResult.html index ecf5bafda39..f033ef84b11 100644 --- a/pr-2980/gear_common/paused_program_storage/struct.ResumeResult.html +++ b/pr-2980/gear_common/paused_program_storage/struct.ResumeResult.html @@ -1,9 +1,9 @@ ResumeResult in gear_common::paused_program_storage - Rust
pub struct ResumeResult<BlockNumber> {
     pub end_block: BlockNumber,
-    pub info: Option<(ProgramId, BlockNumber)>,
+    pub info: Option<(ProgramId, BlockNumber)>,
 }
Expand description

The entity defines result of the PausedProgramStorage::resume_session_commit() method.

Fields§

§end_block: BlockNumber

The session end block number.

-
§info: Option<(ProgramId, BlockNumber)>

If a program resumed successfully then this field contains +

§info: Option<(ProgramId, BlockNumber)>

If a program resumed successfully then this field contains a tuple with id and expiration block of the program.

Auto Trait Implementations§

§

impl<BlockNumber> RefUnwindSafe for ResumeResult<BlockNumber>where BlockNumber: RefUnwindSafe,

§

impl<BlockNumber> Send for ResumeResult<BlockNumber>where diff --git a/pr-2980/gear_common/paused_program_storage/trait.PausedProgramStorage.html b/pr-2980/gear_common/paused_program_storage/trait.PausedProgramStorage.html index be236737fd3..863188ef23f 100644 --- a/pr-2980/gear_common/paused_program_storage/trait.PausedProgramStorage.html +++ b/pr-2980/gear_common/paused_program_storage/trait.PausedProgramStorage.html @@ -1,29 +1,29 @@ PausedProgramStorage in gear_common::paused_program_storage - Rust
pub trait PausedProgramStorage: ProgramStorage {
-    type PausedProgramMap: MapStorage<Key = ProgramId, Value = (Self::BlockNumber, H256)>;
+    type PausedProgramMap: MapStorage<Key = ProgramId, Value = (Self::BlockNumber, H256)>;
     type CodeStorage: CodeStorage;
     type NonceStorage: ValueStorage<Value = SessionId>;
     type ResumeSessions: MapStorage<Key = SessionId, Value = ResumeSession<Self::AccountId, Self::BlockNumber>>;
-    type SessionMemoryPages: AppendMapStorage<(GearPage, PageBuf), SessionId, Vec<(GearPage, PageBuf)>>;
+    type SessionMemoryPages: AppendMapStorage<(GearPage, PageBuf), SessionId, Vec<(GearPage, PageBuf)>>;
 
     // Provided methods
     fn reset() { ... }
-    fn paused_program_exists(program_id: &ProgramId) -> bool { ... }
+    fn paused_program_exists(program_id: &ProgramId) -> bool { ... }
     fn pause_program(
-        program_id: ProgramId,
+        program_id: ProgramId,
         block_number: Self::BlockNumber
-    ) -> Result<GasReservationMap, Self::Error> { ... }
+    ) -> Result<GasReservationMap, Self::Error> { ... }
     fn resume_session_init(
         user: Self::AccountId,
         end_block: Self::BlockNumber,
-        program_id: ProgramId,
-        allocations: BTreeSet<WasmPage>,
-        code_hash: CodeId
+        program_id: ProgramId,
+        allocations: BTreeSet<WasmPage>,
+        code_hash: CodeId
     ) -> Result<SessionId, Self::Error> { ... }
     fn resume_session_page_count(session_id: &SessionId) -> Option<u32> { ... }
     fn resume_session_push(
         session_id: SessionId,
         user: Self::AccountId,
-        memory_pages: Vec<(GearPage, PageBuf)>
+        memory_pages: Vec<(GearPage, PageBuf)>
     ) -> Result<(), Self::Error> { ... }
     fn resume_session_commit(
         session_id: SessionId,
@@ -32,25 +32,25 @@
     ) -> Result<ResumeResult<Self::BlockNumber>, Self::Error> { ... }
     fn remove_resume_session(session_id: SessionId) -> Result<(), Self::Error> { ... }
 }
Expand description

Trait to pause/resume programs.

-

Required Associated Types§

source

type PausedProgramMap: MapStorage<Key = ProgramId, Value = (Self::BlockNumber, H256)>

source

type CodeStorage: CodeStorage

source

type NonceStorage: ValueStorage<Value = SessionId>

source

type ResumeSessions: MapStorage<Key = SessionId, Value = ResumeSession<Self::AccountId, Self::BlockNumber>>

source

type SessionMemoryPages: AppendMapStorage<(GearPage, PageBuf), SessionId, Vec<(GearPage, PageBuf)>>

Provided Methods§

source

fn reset()

Attempt to remove all items from all the associated maps.

-
source

fn paused_program_exists(program_id: &ProgramId) -> bool

Does the paused program (explicitly) exist in storage?

+

Required Associated Types§

Provided Methods§

source

fn reset()

Attempt to remove all items from all the associated maps.

+
source

fn paused_program_exists(program_id: &ProgramId) -> bool

Does the paused program (explicitly) exist in storage?

source

fn pause_program( - program_id: ProgramId, + program_id: ProgramId, block_number: Self::BlockNumber -) -> Result<GasReservationMap, Self::Error>

Pause an active program with the given key program_id.

+) -> Result<GasReservationMap, Self::Error>

Pause an active program with the given key program_id.

Return corresponding map with gas reservations if the program was paused.

source

fn resume_session_init( user: Self::AccountId, end_block: Self::BlockNumber, - program_id: ProgramId, - allocations: BTreeSet<WasmPage>, - code_hash: CodeId + program_id: ProgramId, + allocations: BTreeSet<WasmPage>, + code_hash: CodeId ) -> Result<SessionId, Self::Error>

Create a session for program resume. Returns the session id on success.

source

fn resume_session_page_count(session_id: &SessionId) -> Option<u32>

Get the count of uploaded memory pages of the specified session.

source

fn resume_session_push( session_id: SessionId, user: Self::AccountId, - memory_pages: Vec<(GearPage, PageBuf)> + memory_pages: Vec<(GearPage, PageBuf)> ) -> Result<(), Self::Error>

Append program memory pages to the session data.

source

fn resume_session_commit( session_id: SessionId, diff --git a/pr-2980/gear_common/program_storage/trait.ProgramStorage.html b/pr-2980/gear_common/program_storage/trait.ProgramStorage.html index 6b575bd4e55..75ffa7acdd0 100644 --- a/pr-2980/gear_common/program_storage/trait.ProgramStorage.html +++ b/pr-2980/gear_common/program_storage/trait.ProgramStorage.html @@ -3,9 +3,9 @@ type Error: From<Self::InternalError> + Debug; type BlockNumber: Copy + Saturating; type AccountId: Eq + PartialEq; - type ProgramMap: MapStorage<Key = ProgramId, Value = Program<Self::BlockNumber>>; - type MemoryPageMap: DoubleMapStorage<Key1 = ProgramId, Key2 = GearPage, Value = PageBuf>; - type WaitingInitMap: AppendMapStorage<MessageId, ProgramId, Vec<MessageId>>; + type ProgramMap: MapStorage<Key = ProgramId, Value = Program<Self::BlockNumber>>; + type MemoryPageMap: DoubleMapStorage<Key1 = ProgramId, Key2 = GearPage, Value = PageBuf>; + type WaitingInitMap: AppendMapStorage<MessageId, ProgramId, Vec<MessageId>>;
Show 15 methods // Required method fn pages_final_prefix() -> [u8; 32]; @@ -13,75 +13,75 @@ // Provided methods fn reset() { ... } fn add_program( - program_id: ProgramId, + program_id: ProgramId, program: ActiveProgram<Self::BlockNumber> ) -> Result<(), Self::Error> { ... } - fn get_program(program_id: ProgramId) -> Option<Program<Self::BlockNumber>> { ... } - fn program_exists(program_id: ProgramId) -> bool { ... } + fn get_program(program_id: ProgramId) -> Option<Program<Self::BlockNumber>> { ... } + fn program_exists(program_id: ProgramId) -> bool { ... } fn update_active_program<F, ReturnType>( - program_id: ProgramId, + program_id: ProgramId, update_action: F ) -> Result<ReturnType, Self::Error> where F: FnOnce(&mut ActiveProgram<Self::BlockNumber>) -> ReturnType { ... } fn update_program_if_active<F, ReturnType>( - program_id: ProgramId, + program_id: ProgramId, update_action: F ) -> Result<ReturnType, Self::Error> where F: FnOnce(&mut Program<Self::BlockNumber>, Self::BlockNumber) -> ReturnType { ... } fn get_program_data_for_pages<'a>( - program_id: ProgramId, - pages: impl Iterator<Item = &'a GearPage> + program_id: ProgramId, + pages: impl Iterator<Item = &'a GearPage> ) -> Result<MemoryMap, Self::Error> { ... } fn set_program_page_data( - program_id: ProgramId, - page: GearPage, - page_buf: PageBuf + program_id: ProgramId, + page: GearPage, + page_buf: PageBuf ) { ... } - fn remove_program_page_data(program_id: ProgramId, page_num: GearPage) { ... } - fn remove_program_pages(program_id: ProgramId) { ... } - fn waiting_init_get_messages(program_id: ProgramId) -> Vec<MessageId> { ... } - fn waiting_init_take_messages(program_id: ProgramId) -> Vec<MessageId> { ... } + fn remove_program_page_data(program_id: ProgramId, page_num: GearPage) { ... } + fn remove_program_pages(program_id: ProgramId) { ... } + fn waiting_init_get_messages(program_id: ProgramId) -> Vec<MessageId> { ... } + fn waiting_init_take_messages(program_id: ProgramId) -> Vec<MessageId> { ... } fn waiting_init_append_message_id( - dest_prog_id: ProgramId, - message_id: MessageId + dest_prog_id: ProgramId, + message_id: MessageId ) { ... } - fn waiting_init_remove(program_id: ProgramId) { ... } + fn waiting_init_remove(program_id: ProgramId) { ... }
}
Expand description

Trait to work with program data in a storage.

-

Required Associated Types§

source

type InternalError: Error

source

type Error: From<Self::InternalError> + Debug

source

type BlockNumber: Copy + Saturating

source

type AccountId: Eq + PartialEq

source

type ProgramMap: MapStorage<Key = ProgramId, Value = Program<Self::BlockNumber>>

source

type MemoryPageMap: DoubleMapStorage<Key1 = ProgramId, Key2 = GearPage, Value = PageBuf>

source

type WaitingInitMap: AppendMapStorage<MessageId, ProgramId, Vec<MessageId>>

Required Methods§

source

fn pages_final_prefix() -> [u8; 32]

Final full prefix that prefixes all keys of memory pages.

+

Required Associated Types§

Required Methods§

source

fn pages_final_prefix() -> [u8; 32]

Final full prefix that prefixes all keys of memory pages.

Provided Methods§

source

fn reset()

Attempt to remove all items from all the associated maps.

source

fn add_program( - program_id: ProgramId, + program_id: ProgramId, program: ActiveProgram<Self::BlockNumber> ) -> Result<(), Self::Error>

Store a program to be associated with the given key program_id from the map.

-
source

fn get_program(program_id: ProgramId) -> Option<Program<Self::BlockNumber>>

Load the program associated with the given key program_id from the map.

-
source

fn program_exists(program_id: ProgramId) -> bool

Does the program (explicitly) exist in storage?

+
source

fn get_program(program_id: ProgramId) -> Option<Program<Self::BlockNumber>>

Load the program associated with the given key program_id from the map.

+
source

fn program_exists(program_id: ProgramId) -> bool

Does the program (explicitly) exist in storage?

source

fn update_active_program<F, ReturnType>( - program_id: ProgramId, + program_id: ProgramId, update_action: F ) -> Result<ReturnType, Self::Error>where F: FnOnce(&mut ActiveProgram<Self::BlockNumber>) -> ReturnType,

Update the active program under the given key program_id.

source

fn update_program_if_active<F, ReturnType>( - program_id: ProgramId, + program_id: ProgramId, update_action: F ) -> Result<ReturnType, Self::Error>where F: FnOnce(&mut Program<Self::BlockNumber>, Self::BlockNumber) -> ReturnType,

Update the program under the given key program_id only if the stored program is an active one.

source

fn get_program_data_for_pages<'a>( - program_id: ProgramId, - pages: impl Iterator<Item = &'a GearPage> + program_id: ProgramId, + pages: impl Iterator<Item = &'a GearPage> ) -> Result<MemoryMap, Self::Error>

Return program data for each page from pages.

source

fn set_program_page_data( - program_id: ProgramId, - page: GearPage, - page_buf: PageBuf + program_id: ProgramId, + page: GearPage, + page_buf: PageBuf )

Store a memory page buffer to be associated with the given keys program_id and page from the map.

-
source

fn remove_program_page_data(program_id: ProgramId, page_num: GearPage)

Remove a memory page buffer under the given keys program_id and page.

-
source

fn remove_program_pages(program_id: ProgramId)

Remove all memory page buffers under the given key program_id.

-
source

fn waiting_init_get_messages(program_id: ProgramId) -> Vec<MessageId>

Load the messages to uninitialized program associated with the given key program_id from the map.

-
source

fn waiting_init_take_messages(program_id: ProgramId) -> Vec<MessageId>

Take the messages to uninitialized program under the given key program_id.

+
source

fn remove_program_page_data(program_id: ProgramId, page_num: GearPage)

Remove a memory page buffer under the given keys program_id and page.

+
source

fn remove_program_pages(program_id: ProgramId)

Remove all memory page buffers under the given key program_id.

+
source

fn waiting_init_get_messages(program_id: ProgramId) -> Vec<MessageId>

Load the messages to uninitialized program associated with the given key program_id from the map.

+
source

fn waiting_init_take_messages(program_id: ProgramId) -> Vec<MessageId>

Take the messages to uninitialized program under the given key program_id.

source

fn waiting_init_append_message_id( - dest_prog_id: ProgramId, - message_id: MessageId + dest_prog_id: ProgramId, + message_id: MessageId )

Append the given message id to the list of messages to uninitialized program in the storage.

-
source

fn waiting_init_remove(program_id: ProgramId)

Remove all messages to uninitialized program under the given key program_id.

+
source

fn waiting_init_remove(program_id: ProgramId)

Remove all messages to uninitialized program under the given key program_id.

Implementors§

\ No newline at end of file diff --git a/pr-2980/gear_common/program_storage/type.MemoryMap.html b/pr-2980/gear_common/program_storage/type.MemoryMap.html index 9372f299167..1031da9547e 100644 --- a/pr-2980/gear_common/program_storage/type.MemoryMap.html +++ b/pr-2980/gear_common/program_storage/type.MemoryMap.html @@ -1 +1 @@ -MemoryMap in gear_common::program_storage - Rust

Type Definition gear_common::program_storage::MemoryMap

source ·
pub type MemoryMap = BTreeMap<GearPage, PageBuf>;
\ No newline at end of file +MemoryMap in gear_common::program_storage - Rust

Type Definition gear_common::program_storage::MemoryMap

source ·
pub type MemoryMap = BTreeMap<GearPage, PageBuf>;
\ No newline at end of file diff --git a/pr-2980/gear_common/scheduler/enum.ScheduledTask.html b/pr-2980/gear_common/scheduler/enum.ScheduledTask.html index 8edf9d6d2e4..8da277beafa 100644 --- a/pr-2980/gear_common/scheduler/enum.ScheduledTask.html +++ b/pr-2980/gear_common/scheduler/enum.ScheduledTask.html @@ -1,32 +1,32 @@ ScheduledTask in gear_common::scheduler - Rust
pub enum ScheduledTask<AccountId> {
-    PauseProgram(ProgramId),
-    RemoveCode(CodeId),
-    RemoveFromMailbox(AccountId, MessageId),
-    RemoveFromWaitlist(ProgramId, MessageId),
-    RemovePausedProgram(ProgramId),
-    WakeMessage(ProgramId, MessageId),
-    SendDispatch(MessageId),
+    PauseProgram(ProgramId),
+    RemoveCode(CodeId),
+    RemoveFromMailbox(AccountId, MessageId),
+    RemoveFromWaitlist(ProgramId, MessageId),
+    RemovePausedProgram(ProgramId),
+    WakeMessage(ProgramId, MessageId),
+    SendDispatch(MessageId),
     SendUserMessage {
-        message_id: MessageId,
+        message_id: MessageId,
         to_mailbox: bool,
     },
-    RemoveGasReservation(ProgramId, ReservationId),
+    RemoveGasReservation(ProgramId, ReservationId),
     RemoveResumeSession(SessionId),
 }
Expand description

Scheduled task sense and required data for processing action.

CAUTION: NEVER ALLOW ScheduledTask<AccountId> BE A BIG DATA. To avoid redundant migrations only append new variant(s) to the enum with an explicit corresponding scale codec index.

-

Variants§

§

PauseProgram(ProgramId)

Pause program as out of rent one.

-
§

RemoveCode(CodeId)

Remove code from code storage as out of rent one.

-
§

RemoveFromMailbox(AccountId, MessageId)

Remove message from mailbox as out of rent one.

-
§

RemoveFromWaitlist(ProgramId, MessageId)

Remove message from waitlist as out of rent one.

-
§

RemovePausedProgram(ProgramId)

Remove paused program as dead one (issue #1014).

-
§

WakeMessage(ProgramId, MessageId)

Delayed wake of the message at concrete block.

-
§

SendDispatch(MessageId)

Delayed message to program sending.

+

Variants§

§

PauseProgram(ProgramId)

Pause program as out of rent one.

+
§

RemoveCode(CodeId)

Remove code from code storage as out of rent one.

+
§

RemoveFromMailbox(AccountId, MessageId)

Remove message from mailbox as out of rent one.

+
§

RemoveFromWaitlist(ProgramId, MessageId)

Remove message from waitlist as out of rent one.

+
§

RemovePausedProgram(ProgramId)

Remove paused program as dead one (issue #1014).

+
§

WakeMessage(ProgramId, MessageId)

Delayed wake of the message at concrete block.

+
§

SendDispatch(MessageId)

Delayed message to program sending.

The message itself stored in DispatchStash.

-
§

SendUserMessage

Fields

§message_id: MessageId
§to_mailbox: bool

Delayed message to user sending.

+
§

SendUserMessage

Fields

§message_id: MessageId
§to_mailbox: bool

Delayed message to user sending.

The message itself stored in DispatchStash.

-
§

RemoveGasReservation(ProgramId, ReservationId)

Remove gas reservation.

+
§

RemoveGasReservation(ProgramId, ReservationId)

Remove gas reservation.

§

RemoveResumeSession(SessionId)

Remove resume program session.

Implementations§

source§

impl<AccountId> ScheduledTask<AccountId>

source

pub fn process_with(self, handler: &mut impl TaskHandler<AccountId>)

Trait Implementations§

source§

impl<AccountId: Clone> Clone for ScheduledTask<AccountId>

source§

fn clone(&self) -> ScheduledTask<AccountId>

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl<AccountId: Debug> Debug for ScheduledTask<AccountId>

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<AccountId> Decode for ScheduledTask<AccountId>where AccountId: Decode,

source§

fn decode<__CodecInputEdqy: Input>( diff --git a/pr-2980/gear_common/scheduler/trait.TaskHandler.html b/pr-2980/gear_common/scheduler/trait.TaskHandler.html index 2b0665d1190..3c5c2ed2626 100644 --- a/pr-2980/gear_common/scheduler/trait.TaskHandler.html +++ b/pr-2980/gear_common/scheduler/trait.TaskHandler.html @@ -1,38 +1,38 @@ TaskHandler in gear_common::scheduler - Rust
pub trait TaskHandler<AccountId> {
     // Required methods
-    fn pause_program(&mut self, program_id: ProgramId);
-    fn remove_code(&mut self, code_id: CodeId);
-    fn remove_from_mailbox(&mut self, user_id: AccountId, message_id: MessageId);
+    fn pause_program(&mut self, program_id: ProgramId);
+    fn remove_code(&mut self, code_id: CodeId);
+    fn remove_from_mailbox(&mut self, user_id: AccountId, message_id: MessageId);
     fn remove_from_waitlist(
         &mut self,
-        program_id: ProgramId,
-        message_id: MessageId
+        program_id: ProgramId,
+        message_id: MessageId
     );
-    fn remove_paused_program(&mut self, program_id: ProgramId);
-    fn wake_message(&mut self, program_id: ProgramId, message_id: MessageId);
-    fn send_dispatch(&mut self, stashed_message_id: MessageId);
+    fn remove_paused_program(&mut self, program_id: ProgramId);
+    fn wake_message(&mut self, program_id: ProgramId, message_id: MessageId);
+    fn send_dispatch(&mut self, stashed_message_id: MessageId);
     fn send_user_message(
         &mut self,
-        stashed_message_id: MessageId,
+        stashed_message_id: MessageId,
         to_mailbox: bool
     );
     fn remove_gas_reservation(
         &mut self,
-        program_id: ProgramId,
-        reservation_id: ReservationId
+        program_id: ProgramId,
+        reservation_id: ReservationId
     );
     fn remove_resume_session(&mut self, session_id: SessionId);
 }
Expand description

Task handler trait for dealing with required tasks.

-

Required Methods§

source

fn pause_program(&mut self, program_id: ProgramId)

Pause program action.

-
source

fn remove_code(&mut self, code_id: CodeId)

Remove code action.

-
source

fn remove_from_mailbox(&mut self, user_id: AccountId, message_id: MessageId)

Remove from mailbox action.

-
source

fn remove_from_waitlist(&mut self, program_id: ProgramId, message_id: MessageId)

Remove from waitlist action.

-
source

fn remove_paused_program(&mut self, program_id: ProgramId)

Remove paused program action.

-
source

fn wake_message(&mut self, program_id: ProgramId, message_id: MessageId)

Wake message action.

-
source

fn send_dispatch(&mut self, stashed_message_id: MessageId)

source

fn send_user_message(&mut self, stashed_message_id: MessageId, to_mailbox: bool)

source

fn remove_gas_reservation( +

Required Methods§

source

fn pause_program(&mut self, program_id: ProgramId)

Pause program action.

+
source

fn remove_code(&mut self, code_id: CodeId)

Remove code action.

+
source

fn remove_from_mailbox(&mut self, user_id: AccountId, message_id: MessageId)

Remove from mailbox action.

+
source

fn remove_from_waitlist(&mut self, program_id: ProgramId, message_id: MessageId)

Remove from waitlist action.

+
source

fn remove_paused_program(&mut self, program_id: ProgramId)

Remove paused program action.

+
source

fn wake_message(&mut self, program_id: ProgramId, message_id: MessageId)

Wake message action.

+
source

fn send_dispatch(&mut self, stashed_message_id: MessageId)

source

fn send_user_message(&mut self, stashed_message_id: MessageId, to_mailbox: bool)

source

fn remove_gas_reservation( &mut self, - program_id: ProgramId, - reservation_id: ReservationId + program_id: ProgramId, + reservation_id: ReservationId )

Remove gas reservation action.

source

fn remove_resume_session(&mut self, session_id: SessionId)

Remove data created by resume program session.

Implementors§

\ No newline at end of file diff --git a/pr-2980/gear_common/storage/struct.MailboxKeyGen.html b/pr-2980/gear_common/storage/struct.MailboxKeyGen.html index dbd5963fa6e..aec850067c6 100644 --- a/pr-2980/gear_common/storage/struct.MailboxKeyGen.html +++ b/pr-2980/gear_common/storage/struct.MailboxKeyGen.html @@ -1,5 +1,5 @@ MailboxKeyGen in gear_common::storage - Rust
pub struct MailboxKeyGen<T>(_);
Expand description

Key generator for gear’s mailbox implementation.

-

Trait Implementations§

source§

impl<T: Origin> KeyFor for MailboxKeyGen<T>

§

type Key = (T, MessageId)

Generated key type.
§

type Value = UserStoredMessage

Value over which key should be generated type.
source§

fn key_for(value: &Self::Value) -> Self::Key

Generates key for given by reference Value.

Auto Trait Implementations§

§

impl<T> RefUnwindSafe for MailboxKeyGen<T>where +

Trait Implementations§

source§

impl<T: Origin> KeyFor for MailboxKeyGen<T>

§

type Key = (T, MessageId)

Generated key type.
§

type Value = UserStoredMessage

Value over which key should be generated type.
source§

fn key_for(value: &Self::Value) -> Self::Key

Generates key for given by reference Value.

Auto Trait Implementations§

§

impl<T> RefUnwindSafe for MailboxKeyGen<T>where T: RefUnwindSafe,

§

impl<T> Send for MailboxKeyGen<T>where T: Send,

§

impl<T> Sync for MailboxKeyGen<T>where T: Sync,

§

impl<T> Unpin for MailboxKeyGen<T>where diff --git a/pr-2980/gear_common/storage/struct.QueueKeyGen.html b/pr-2980/gear_common/storage/struct.QueueKeyGen.html index e8970a88703..cdf877b1e62 100644 --- a/pr-2980/gear_common/storage/struct.QueueKeyGen.html +++ b/pr-2980/gear_common/storage/struct.QueueKeyGen.html @@ -1,5 +1,5 @@ QueueKeyGen in gear_common::storage - Rust
pub struct QueueKeyGen;
Expand description

Key generator for gear’s message queue implementation.

-

Trait Implementations§

source§

impl KeyFor for QueueKeyGen

§

type Key = MessageId

Generated key type.
§

type Value = StoredDispatch

Value over which key should be generated type.
source§

fn key_for(value: &Self::Value) -> Self::Key

Generates key for given by reference Value.

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for Twhere +

Trait Implementations§

source§

impl KeyFor for QueueKeyGen

§

type Key = MessageId

Generated key type.
§

type Value = StoredDispatch

Value over which key should be generated type.
source§

fn key_for(value: &Self::Value) -> Self::Key

Generates key for given by reference Value.

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for Twhere T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for Twhere T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for Twhere T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
§

impl<T> CheckedConversion for T

§

fn checked_from<T>(t: T) -> Option<Self>where diff --git a/pr-2980/gear_common/storage/struct.WaitlistKeyGen.html b/pr-2980/gear_common/storage/struct.WaitlistKeyGen.html index 57953cbaf0b..132166a9a9d 100644 --- a/pr-2980/gear_common/storage/struct.WaitlistKeyGen.html +++ b/pr-2980/gear_common/storage/struct.WaitlistKeyGen.html @@ -1,5 +1,5 @@ WaitlistKeyGen in gear_common::storage - Rust
pub struct WaitlistKeyGen;
Expand description

Key generator for gear’s waitlist implementation.

-

Trait Implementations§

source§

impl KeyFor for WaitlistKeyGen

§

type Key = (ProgramId, MessageId)

Generated key type.
§

type Value = StoredDispatch

Value over which key should be generated type.
source§

fn key_for(value: &Self::Value) -> Self::Key

Generates key for given by reference Value.

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for Twhere +

Trait Implementations§

source§

impl KeyFor for WaitlistKeyGen

§

type Key = (ProgramId, MessageId)

Generated key type.
§

type Value = StoredDispatch

Value over which key should be generated type.
source§

fn key_for(value: &Self::Value) -> Self::Key

Generates key for given by reference Value.

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for Twhere T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for Twhere T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for Twhere T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
§

impl<T> CheckedConversion for T

§

fn checked_from<T>(t: T) -> Option<Self>where diff --git a/pr-2980/gear_common/storage/trait.KeyFor.html b/pr-2980/gear_common/storage/trait.KeyFor.html index 61789ec88f7..fc9a2b0c9ce 100644 --- a/pr-2980/gear_common/storage/trait.KeyFor.html +++ b/pr-2980/gear_common/storage/trait.KeyFor.html @@ -10,4 +10,4 @@

Required Associated Types§

source

type Key

Generated key type.

source

type Value

Value over which key should be generated type.

Required Methods§

source

fn key_for(value: &Self::Value) -> Self::Key

Generates key for given by reference Value.

-

Implementors§

source§

impl KeyFor for QueueKeyGen

§

type Key = MessageId

§

type Value = StoredDispatch

source§

impl KeyFor for WaitlistKeyGen

§

type Key = (ProgramId, MessageId)

§

type Value = StoredDispatch

source§

impl<T: Origin> KeyFor for MailboxKeyGen<T>

§

type Key = (T, MessageId)

§

type Value = UserStoredMessage

\ No newline at end of file +

Implementors§

\ No newline at end of file diff --git a/pr-2980/gear_common/struct.ActiveProgram.html b/pr-2980/gear_common/struct.ActiveProgram.html index 3fdd149fce4..7803d573f73 100644 --- a/pr-2980/gear_common/struct.ActiveProgram.html +++ b/pr-2980/gear_common/struct.ActiveProgram.html @@ -1,15 +1,15 @@ ActiveProgram in gear_common - Rust
pub struct ActiveProgram<BlockNumber: Copy + Saturating> {
-    pub allocations: BTreeSet<WasmPage>,
-    pub pages_with_data: BTreeSet<GearPage>,
-    pub gas_reservation_map: GasReservationMap,
+    pub allocations: BTreeSet<WasmPage>,
+    pub pages_with_data: BTreeSet<GearPage>,
+    pub gas_reservation_map: GasReservationMap,
     pub code_hash: H256,
-    pub code_exports: BTreeSet<DispatchKind>,
-    pub static_pages: WasmPage,
+    pub code_exports: BTreeSet<DispatchKind>,
+    pub static_pages: WasmPage,
     pub state: ProgramState,
     pub expiration_block: BlockNumber,
-}

Fields§

§allocations: BTreeSet<WasmPage>

Set of dynamic wasm page numbers, which are allocated by the program.

-
§pages_with_data: BTreeSet<GearPage>

Set of gear pages numbers, which has data in storage.

-
§gas_reservation_map: GasReservationMap§code_hash: H256§code_exports: BTreeSet<DispatchKind>§static_pages: WasmPage§state: ProgramState§expiration_block: BlockNumber

Trait Implementations§

source§

impl<BlockNumber: Clone + Copy + Saturating> Clone for ActiveProgram<BlockNumber>

source§

fn clone(&self) -> ActiveProgram<BlockNumber>

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl<BlockNumber: Debug + Copy + Saturating> Debug for ActiveProgram<BlockNumber>

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<BlockNumber> Decode for ActiveProgram<BlockNumber>where +}

Fields§

§allocations: BTreeSet<WasmPage>

Set of dynamic wasm page numbers, which are allocated by the program.

+
§pages_with_data: BTreeSet<GearPage>

Set of gear pages numbers, which has data in storage.

+
§gas_reservation_map: GasReservationMap§code_hash: H256§code_exports: BTreeSet<DispatchKind>§static_pages: WasmPage§state: ProgramState§expiration_block: BlockNumber

Trait Implementations§

source§

impl<BlockNumber: Clone + Copy + Saturating> Clone for ActiveProgram<BlockNumber>

source§

fn clone(&self) -> ActiveProgram<BlockNumber>

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl<BlockNumber: Debug + Copy + Saturating> Debug for ActiveProgram<BlockNumber>

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<BlockNumber> Decode for ActiveProgram<BlockNumber>where BlockNumber: Decode + Copy + Saturating,

source§

fn decode<__CodecInputEdqy: Input>( __codec_input_edqy: &mut __CodecInputEdqy ) -> Result<Self, Error>

Attempt to deserialise the value from input.
§

fn decode_into<I>( diff --git a/pr-2980/gear_common/trait.Origin.html b/pr-2980/gear_common/trait.Origin.html index 76bb89dd18d..cb9e5cda12a 100644 --- a/pr-2980/gear_common/trait.Origin.html +++ b/pr-2980/gear_common/trait.Origin.html @@ -2,4 +2,4 @@ // Required methods fn into_origin(self) -> H256; fn from_origin(val: H256) -> Self; -}

Required Methods§

source

fn into_origin(self) -> H256

source

fn from_origin(val: H256) -> Self

Implementations on Foreign Types§

source§

impl Origin for MessageId

source§

fn into_origin(self) -> H256

source§

fn from_origin(val: H256) -> Self

source§

impl Origin for CodeId

source§

fn into_origin(self) -> H256

source§

fn from_origin(val: H256) -> Self

source§

impl Origin for ProgramId

source§

fn into_origin(self) -> H256

source§

fn from_origin(val: H256) -> Self

source§

impl Origin for H256

source§

fn into_origin(self) -> H256

source§

fn from_origin(val: H256) -> Self

source§

impl Origin for u64

source§

fn into_origin(self) -> H256

source§

fn from_origin(v: H256) -> Self

source§

impl Origin for AccountId32

source§

fn into_origin(self) -> H256

source§

fn from_origin(v: H256) -> Self

Implementors§

\ No newline at end of file +}

Required Methods§

source

fn into_origin(self) -> H256

source

fn from_origin(val: H256) -> Self

Implementations on Foreign Types§

source§

impl Origin for MessageId

source§

fn into_origin(self) -> H256

source§

fn from_origin(val: H256) -> Self

source§

impl Origin for CodeId

source§

fn into_origin(self) -> H256

source§

fn from_origin(val: H256) -> Self

source§

impl Origin for ProgramId

source§

fn into_origin(self) -> H256

source§

fn from_origin(val: H256) -> Self

source§

impl Origin for H256

source§

fn into_origin(self) -> H256

source§

fn from_origin(val: H256) -> Self

source§

impl Origin for u64

source§

fn into_origin(self) -> H256

source§

fn from_origin(v: H256) -> Self

source§

impl Origin for AccountId32

source§

fn into_origin(self) -> H256

source§

fn from_origin(v: H256) -> Self

Implementors§

\ No newline at end of file diff --git a/pr-2980/implementors/core/convert/trait.From.js b/pr-2980/implementors/core/convert/trait.From.js index 55a416e566e..01fc60d8094 100644 --- a/pr-2980/implementors/core/convert/trait.From.js +++ b/pr-2980/implementors/core/convert/trait.From.js @@ -2,7 +2,7 @@ "gclient":[["impl From<Error> for Error"],["impl From<Error> for Error"],["impl From<ParseError> for Error"],["impl From<DispatchStatus> for DispatchStatus"],["impl From<Error> for Error"],["impl From<Error> for Error"],["impl From<SocketAddrV4> for WSAddress"],["impl From<Error> for Error"],["impl From<FromHexError> for Error"],["impl From<Error> for Error"]], "gcore":[["impl From<SyscallError> for Result<()>"],["impl From<ExtError> for Error"],["impl From<[u8; 32]> for CodeId"],["impl From<u64> for ActorId"],["impl From<[u8; 32]> for ReservationId"]], "gear_backend_common":[["impl From<ProcessAccessError> for MemoryAccessError"],["impl<E> From<E> for RunFallibleErrorwhere\n E: BackendSyscallError,"],["impl From<RuntimeBufferSizeError> for MemoryAccessError"],["impl From<UnrecoverableMemoryError> for UnrecoverableExtError"],["impl From<SystemTerminationReason> for TerminationReason"],["impl From<UnrecoverableExecutionError> for UnrecoverableExtError"],["impl From<ActorTerminationReason> for TerminationReason"],["impl From<ChargeError> for TerminationReason"],["impl From<LimitedStr<'static>> for TrapExplanation"],["impl From<()> for MemoryAccessError"],["impl From<MemoryError> for MemoryAccessError"],["impl<'a> From<String> for LimitedStr<'a>"],["impl From<UnrecoverableExtError> for TrapExplanation"],["impl From<TrapExplanation> for TerminationReason"],["impl From<UnrecoverableWaitError> for UnrecoverableExtError"],["impl From<TrapExplanation> for ActorTerminationReason"],["impl<E: BackendSyscallError> From<E> for TerminationReason"]], -"gear_common":[["impl<U> From<MessageId> for GasNodeId<MessageId, U>"],["impl<T> From<ReservationId> for GasNodeId<T, ReservationId>"],["impl From<MessageWaitedType> for MessageWaitedRuntimeReason"],["impl<I, Item, TC> From<I> for IteratorWrap<I, Item, TC>where\n I: Iterator,\n TC: TransposeCallback<I::Item, Item>,"]], +"gear_common":[["impl<U> From<MessageId> for GasNodeId<MessageId, U>"],["impl<T> From<ReservationId> for GasNodeId<T, ReservationId>"],["impl From<MessageWaitedType> for MessageWaitedRuntimeReason"],["impl<I, Item, TC> From<I> for IteratorWrap<I, Item, TC>where\n I: Iterator,\n TC: TransposeCallback<I::Item, Item>,"]], "gear_core":[["impl From<u16> for GearPage"],["impl From<IncorrectAllocationDataError> for AllocError"],["impl From<StoredDispatch> for (DispatchKind, StoredMessage, Option<ContextStore>)"],["impl From<CodeId> for [u8; 32]"],["impl From<IncomingDispatch> for (DispatchKind, IncomingMessage, Option<ContextStore>)"],["impl From<u16> for WasmPage"],["impl From<SignalDetails> for MessageDetails"],["impl From<&[u8]> for ProgramId"],["impl From<PayloadSizeError> for &str"],["impl From<(&mut MessageContext, &mut PayloadSliceLock)> for UnlockPayloadBound"],["impl From<ReplyDetails> for MessageDetails"],["impl From<ChargeError> for AllocError"],["impl From<u64> for ReservationId"],["impl From<[u8; 32]> for ProgramId"],["impl From<RuntimeBufferSizeError> for &str"],["impl From<Message> for StoredMessage"],["impl From<GasReservationSlot> for GasReservationState"],["impl From<&[u8]> for ReservationId"],["impl From<[u8; 32]> for CodeId"],["impl From<UserMessage> for StoredMessage"],["impl<JobErr> From<(UnlockPayloadBound, Result<(), JobErr>)> for DropPayloadLockBound<JobErr>"],["impl From<u64> for ProgramId"],["impl From<&[u8]> for MessageId"],["impl From<MemoryInterval> for (u32, u32)"],["impl From<[u8; 32]> for MessageId"],["impl From<Dispatch> for StoredDispatch"],["impl From<ReservationId> for [u8; 32]"],["impl From<[u8; 32]> for ReservationId"],["impl From<(u64, u64)> for GasLeft"],["impl From<u64> for CodeId"],["impl<P: PageU32Size> From<CostPerPage<P>> for u64"],["impl From<MessageId> for [u8; 32]"],["impl From<(u32, u32)> for MemoryInterval"],["impl From<RuntimeToken> for u64"],["impl From<GearPage> for u32"],["impl From<(i64, i64)> for GasLeft"],["impl From<WasmPage> for u32"],["impl From<UserStoredMessage> for StoredMessage"],["impl<P: PageU32Size> From<u64> for CostPerPage<P>"],["impl From<&[u8]> for CodeId"],["impl From<u64> for MessageId"],["impl From<Dispatch> for (DispatchKind, Message)"],["impl From<CodeAndId> for InstrumentedCodeAndId"],["impl From<ProgramId> for [u8; 32]"]], "gear_core_errors":[["impl From<ErrorReplyReason> for ReplyCode"],["impl From<SimpleExecutionError> for SignalCode"],["impl From<SimpleProgramCreationError> for ErrorReplyReason"],["impl From<ExecutionError> for ExtError"],["impl From<()> for ReplyCode"],["impl From<MemoryError> for ExtError"],["impl From<ProgramRentError> for ExtError"],["impl From<SuccessReplyReason> for ReplyCode"],["impl From<()> for SignalCode"],["impl From<SimpleExecutionError> for ErrorReplyReason"],["impl From<ReservationError> for ExtError"],["impl From<MessageError> for ExtError"],["impl From<()> for ExtError"]], "gear_core_processor":[["impl From<SystemTerminationReason> for SystemExecutionError"],["impl From<AllocError> for AllocExtError"],["impl From<ChargeError> for AllocExtError"],["impl From<UnrecoverableExecutionError> for UnrecoverableExtError"],["impl From<UnrecoverableExtError> for UnrecoverableExtError"],["impl From<ProgramRentError> for FallibleExtError"],["impl From<FallibleExtError> for RunFallibleError"],["impl From<MessageError> for FallibleExtError"],["impl From<UnrecoverableWaitError> for UnrecoverableExtError"],["impl From<SystemExecutionError> for ExecutionError"],["impl From<ChargeError> for UnrecoverableExtError"],["impl From<(ContextChargedForCodeLength, u32)> for ContextChargedForCode"],["impl From<(ContextChargedForMemory, InstrumentedCode, u128)> for ProcessExecutionContext"],["impl From<(IncomingDispatch, GasCounter, GasAllowanceCounter)> for PrechargedDispatch"],["impl From<()> for FallibleExtError"],["impl From<ActorExecutionError> for ExecutionError"],["impl From<ContextChargedForCode> for ContextChargedForInstrumentation"],["impl From<ExecutionError> for FallibleExtError"],["impl From<ExtError> for FallibleExtError"],["impl From<ChargeError> for FallibleExtError"],["impl From<ReservationError> for FallibleExtError"]],