fn validate_transaction(&self, at: &BlockId<Self::Block>, uxt: ExtrinsicFor<Self>) -> Result<TransactionValidity, Self::Error> {

			let block_number = self.block_id_to_number(at)?.unwrap();
			let nonce = uxt.transfer().nonce;

			// This is used to control the test flow.
			if nonce > 0 {
				let opt = self.delay.lock().take();
				if let Some(delay) = opt {
					if delay.recv().is_err() {
						println!("Error waiting for delay!");
					}
				}
			}

			if nonce < block_number {
				Ok(TransactionValidity::Invalid(0))
			} else {
				Ok(TransactionValidity::Valid {
					priority: 4,
					requires: if nonce > block_number { vec![vec![nonce as u8 - 1]] } else { vec![] },
					provides: vec![vec![nonce as u8]],
					longevity: 3,
				})
			}
		}
/// Verify extrinsic at given block.
Verify extrinsic at given block.
Verify extrinsic at given block .
fn validate_transaction(&self, at: &BlockId<Self::Block>, uxt: ExtrinsicFor<Self>) -> Result<TransactionValidity, Self::Error> {
			let block_number = self.block_id_to_number(at)?.unwrap();
			let nonce = uxt.transfer().nonce;
			// This is used to control the test flow.
			if nonce > 0 {
				let opt = self.delay.lock().take();
				if let Some(delay) = opt {
					if delay.recv().is_err() {
						println!("Error waiting for delay!");
					}
				}
			}
			if nonce < block_number {
				Ok(TransactionValidity::Invalid(0))
			} else {
				Ok(TransactionValidity::Valid {
					priority: 4,
					requires: if nonce > block_number { vec![vec![nonce as u8 - 1]] } else { vec![] },
					provides: vec![vec![nonce as u8]],
					longevity: 3,
				})
			}
		}
fn validate_transaction ( & self , at : & BlockId < Self :: Block > , uxt : ExtrinsicFor < Self > ) -> Result < TransactionValidity , Self :: Error > { let block_number = self . block_id_to_number ( at ) ? . unwrap ( ) ; let nonce = uxt . transfer ( ) . nonce ; // This is used to control the test flow. if nonce > 0 { let opt = self . delay . lock ( ) . take ( ) ; if let Some ( delay ) = opt { if delay . recv ( ) . is_err ( ) { println ! ( " " ) ; } } } if nonce < block_number { Ok ( TransactionValidity :: Invalid ( 0 ) ) } else { Ok ( TransactionValidity :: Valid { priority : 4 , requires : if nonce > block_number { vec ! [ vec [ nonce as u8 1 ] ] } else { vec ! [ ] } , provides : vec ! [ vec [ nonce as u8 ] ] , longevity : 3 , } ) } }
Verify extrinsic at given block.
Verify extrinsic at given block .
&self
at
&BlockId<Self::Block>
uxt
ExtrinsicFor<Self>
&self
at
&BlockId<Self::Block>
uxt
ExtrinsicFor<Self>