コード例 #1
0
ファイル: AbstractJson2PHP.php プロジェクト: ecs-hk/Checkbook
 public function convert($input)
 {
     $cleanedInput = NULL;
     if ($this->cleanInput) {
         $stripperComment = new CommentStripper();
         $stripperWhiteCharacter = new WhiteCharacterStripper();
         $cleanedInput = $stripperWhiteCharacter->convert($stripperComment->convert($input));
     }
     return json_decode(isset($cleanedInput) ? $cleanedInput : $input, $this->returnAsAssociativeArray);
 }
    public function clean($expression) {
        $stripperWhiteCharacter = new WhiteCharacterStripper();

        return $stripperWhiteCharacter->convert($expression);
    }
コード例 #3
0
    protected function cleanInput($input) {
        $stripperComment = new CommentStripper();
        $stripperWhiteCharacter = new WhiteCharacterStripper();

        return $stripperWhiteCharacter->convert($stripperComment->convert($input));
    }