original_string: public static function getStringValueAsCode($value): string
      {
          if ($value instanceof \DateTime) {
              return "new \DateTime('".$value->format(self::DEFAULT_DATETIME_FORMAT)."')";
          } elseif (is_bool($value)) {
              return $value ? 'true' : 'false';
          } elseif (is_array($value)) {
              return '['.implode(', ', array_map('self::getStringValueAsCode', array_filter($value))).']';
          } elseif (is_null($value)) {
              return 'null';
          } elseif (is_int($value) || is_float($value)) {
              return (string) $value;
          }
  
          return "'".(string) $value."'";
      }
code: public static function getStringValueAsCode($value): string
      {
          if ($value instanceof \DateTime) {
              return "new \DateTime('".$value->format(self::DEFAULT_DATETIME_FORMAT)."')";
          } elseif (is_bool($value)) {
              return $value ? 'true' : 'false';
          } elseif (is_array($value)) {
              return '['.implode(', ', array_map('self::getStringValueAsCode', array_filter($value))).']';
          } elseif (is_null($value)) {
              return 'null';
          } elseif (is_int($value) || is_float($value)) {
              return (string) $value;
          }
  
          return "'".(string) $value."'";
      }
code_tokens: public static function getStringValueAsCode ( $ value ) : string { if ( $ value instanceof \ DateTime ) { return "new \DateTime('" . $ value -> format ( self :: DEFAULT_DATETIME_FORMAT ) . "')" ; } elseif ( is_bool ( $ value ) ) { return $ value ? 'true' : 'false' ; } elseif ( is_array ( $ value ) ) { return '[' . implode ( ', ' , array_map ( 'self::getStringValueAsCode' , array_filter ( $ value ) ) ) . ']' ; } elseif ( is_null ( $ value ) ) { return 'null' ; } elseif ( is_int ( $ value ) || is_float ( $ value ) ) { return ( string ) $ value ; } return "'" . ( string ) $ value . "'" ; }
docstring: Get string display output for showing code based on the value.
  
  @param mixed $value
  @return string
docstring_tokens: Get string display output for showing code based on the value .