method

binary?

Importance_0
v1_9_3_125 - Show latest stable - 0 notes - Class: YAMLTree
binary?(string) private

No documentation

This method has no description. You can help the Ruby community by adding new notes.

Hide source
# File ext/psych/lib/psych/visitors/yaml_tree.rb, line 217
      def binary? string
        string.encoding == Encoding::ASCII_8BIT ||
          string.index("\x00") ||
          string.count("\x00-\x7F", "^ -~\t\r\n").fdiv(string.length) > 0.3
      end
Register or log in to add new notes.