1<?php 2namespace Hidehalo\Nanoid; 3 4interface CoreInterface 5{ 6 const SAFE_SYMBOLS = '_-0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ'; 7 const MASKS = [15, 31, 63, 127, 255]; 8 9 /** 10 * Secure random string generator with custom alphabet. 11 * Alphabet must contain 256 symbols or less. Otherwise, the generator 12 * will not be secure. 13 * 14 * @param GeneratorInterface $generator 15 * @param string $alphabet 16 * @param integer $size 17 */ 18 public function random(GeneratorInterface $generator, $size, $alphabet = CoreInterface::SAFE_SYMBOLS); 19} 20