# Trait ring::rand::SecureRandom [−] [src]

    pub trait SecureRandom {
        fn fill(&self, dest: &mut [u8]) -> Result<(), Unspecified>;
    }

A secure random number generator.

## Required Methods

### `fn fill(&self, dest: &mut [u8]) -> Result<(), Unspecified>`

Fills `dest` with random bytes.

## Implementors

- `impl SecureRandom for SystemRandom`
- `impl SecureRandom for FixedByteRandom`
- `impl<'a> SecureRandom for FixedSliceRandom<'a>`
- `impl<'a> SecureRandom for FixedSliceSequenceRandom<'a>`

# Help

## Keyboard Shortcuts

?
  Show this help dialog
S
  Focus the search field
⇤
  Move up in search results
⇥
  Move down in search results
⏎
  Go to active search result
+
  Collapse/expand all sections

## Search Tricks

Prefix searches with a type followed by a colon (e.g. `fn:`) to restrict the search to a given type.

Accepted types are: `fn`, `mod`, `struct`, `enum`, `trait`, `type`, `macro`, and `const`.

Search functions by type signature (e.g. `vec -> usize` or `* -> vec`)