orientdb 0.0.20-jruby → 0.0.21-jruby
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/VERSION +1 -1
 - data/lib/orientdb/database.rb +6 -0
 - data/lib/orientdb/oclass.rb +6 -2
 - data/orientdb.gemspec +2 -2
 - metadata +2 -2
 
    
        data/VERSION
    CHANGED
    
    | 
         @@ -1 +1 @@ 
     | 
|
| 
       1 
     | 
    
         
            -
            0.0. 
     | 
| 
      
 1 
     | 
    
         
            +
            0.0.21
         
     | 
    
        data/lib/orientdb/database.rb
    CHANGED
    
    | 
         @@ -6,6 +6,8 @@ module OrientDB 
     | 
|
| 
       6 
6 
     | 
    
         
             
                  command(sql_command).execute(true)
         
     | 
| 
       7 
7 
     | 
    
         
             
                end
         
     | 
| 
       8 
8 
     | 
    
         | 
| 
      
 9 
     | 
    
         
            +
                alias :cmd :run_command
         
     | 
| 
      
 10 
     | 
    
         
            +
             
     | 
| 
       9 
11 
     | 
    
         
             
                def prepare_sql_command(command)
         
     | 
| 
       10 
12 
     | 
    
         
             
                  return if command.nil?
         
     | 
| 
       11 
13 
     | 
    
         
             
                  return command.to_sql_command if command.respond_to?(:to_sql_command)
         
     | 
| 
         @@ -84,6 +86,10 @@ module OrientDB 
     | 
|
| 
       84 
86 
     | 
    
         
             
                  browse_cluster(cluster_name.to_s).map
         
     | 
| 
       85 
87 
     | 
    
         
             
                end
         
     | 
| 
       86 
88 
     | 
    
         | 
| 
      
 89 
     | 
    
         
            +
                def quote(value)
         
     | 
| 
      
 90 
     | 
    
         
            +
                  SQL::Query.quote value
         
     | 
| 
      
 91 
     | 
    
         
            +
                end
         
     | 
| 
      
 92 
     | 
    
         
            +
             
     | 
| 
       87 
93 
     | 
    
         
             
              end
         
     | 
| 
       88 
94 
     | 
    
         | 
| 
       89 
95 
     | 
    
         
             
              class DocumentDatabase
         
     | 
    
        data/lib/orientdb/oclass.rb
    CHANGED
    
    | 
         @@ -3,7 +3,7 @@ module OrientDB 
     | 
|
| 
       3 
3 
     | 
    
         
             
              class OClassImpl
         
     | 
| 
       4 
4 
     | 
    
         | 
| 
       5 
5 
     | 
    
         
             
                def type_for(value)
         
     | 
| 
       6 
     | 
    
         
            -
                  self.class.type_for value
         
     | 
| 
      
 6 
     | 
    
         
            +
                  self.class.type_for value, schema
         
     | 
| 
       7 
7 
     | 
    
         
             
                end
         
     | 
| 
       8 
8 
     | 
    
         | 
| 
       9 
9 
     | 
    
         
             
                def add(property_name, type, options = { })
         
     | 
| 
         @@ -40,6 +40,10 @@ module OrientDB 
     | 
|
| 
       40 
40 
     | 
    
         
             
                  self
         
     | 
| 
       41 
41 
     | 
    
         
             
                end
         
     | 
| 
       42 
42 
     | 
    
         | 
| 
      
 43 
     | 
    
         
            +
                def add_index
         
     | 
| 
      
 44 
     | 
    
         
            +
             
     | 
| 
      
 45 
     | 
    
         
            +
                end
         
     | 
| 
      
 46 
     | 
    
         
            +
             
     | 
| 
       43 
47 
     | 
    
         
             
                def [](property_name)
         
     | 
| 
       44 
48 
     | 
    
         
             
                  property_name = property_name.to_s
         
     | 
| 
       45 
49 
     | 
    
         
             
                  exists_property(property_name) ? get_property(property_name) : nil
         
     | 
| 
         @@ -65,7 +69,7 @@ module OrientDB 
     | 
|
| 
       65 
69 
     | 
    
         | 
| 
       66 
70 
     | 
    
         
             
                class << self
         
     | 
| 
       67 
71 
     | 
    
         | 
| 
       68 
     | 
    
         
            -
                  def type_for(value)
         
     | 
| 
      
 72 
     | 
    
         
            +
                  def type_for(value, schema)
         
     | 
| 
       69 
73 
     | 
    
         
             
                    value = value.oclass if value.respond_to?(:oclass)
         
     | 
| 
       70 
74 
     | 
    
         
             
                    type = case value
         
     | 
| 
       71 
75 
     | 
    
         
             
                             when OrientDB::SchemaType, OrientDB::OClassImpl
         
     | 
    
        data/orientdb.gemspec
    CHANGED
    
    | 
         @@ -5,12 +5,12 @@ 
     | 
|
| 
       5 
5 
     | 
    
         | 
| 
       6 
6 
     | 
    
         
             
            Gem::Specification.new do |s|
         
     | 
| 
       7 
7 
     | 
    
         
             
              s.name = %q{orientdb}
         
     | 
| 
       8 
     | 
    
         
            -
              s.version = "0.0. 
     | 
| 
      
 8 
     | 
    
         
            +
              s.version = "0.0.21"
         
     | 
| 
       9 
9 
     | 
    
         
             
              s.platform = %q{jruby}
         
     | 
| 
       10 
10 
     | 
    
         | 
| 
       11 
11 
     | 
    
         
             
              s.required_rubygems_version = Gem::Requirement.new(">= 1.3.6") if s.respond_to? :required_rubygems_version=
         
     | 
| 
       12 
12 
     | 
    
         
             
              s.authors = [%q{Adrian Madrid}]
         
     | 
| 
       13 
     | 
    
         
            -
              s.date = %q{ 
     | 
| 
      
 13 
     | 
    
         
            +
              s.date = %q{2012-01-12}
         
     | 
| 
       14 
14 
     | 
    
         
             
              s.description = %q{Simple JRuby wrapper for the OrientDB.}
         
     | 
| 
       15 
15 
     | 
    
         
             
              s.email = [%q{aemadrid@gmail.com}]
         
     | 
| 
       16 
16 
     | 
    
         
             
              s.executables = [%q{orientdb_console}]
         
     | 
    
        metadata
    CHANGED
    
    | 
         @@ -2,7 +2,7 @@ 
     | 
|
| 
       2 
2 
     | 
    
         
             
            name: orientdb
         
     | 
| 
       3 
3 
     | 
    
         
             
            version: !ruby/object:Gem::Version 
         
     | 
| 
       4 
4 
     | 
    
         
             
              prerelease: 
         
     | 
| 
       5 
     | 
    
         
            -
              version: 0.0. 
     | 
| 
      
 5 
     | 
    
         
            +
              version: 0.0.21
         
     | 
| 
       6 
6 
     | 
    
         
             
            platform: jruby
         
     | 
| 
       7 
7 
     | 
    
         
             
            authors: 
         
     | 
| 
       8 
8 
     | 
    
         
             
              - Adrian Madrid
         
     | 
| 
         @@ -10,7 +10,7 @@ autorequire: 
     | 
|
| 
       10 
10 
     | 
    
         
             
            bindir: bin
         
     | 
| 
       11 
11 
     | 
    
         
             
            cert_chain: []
         
     | 
| 
       12 
12 
     | 
    
         | 
| 
       13 
     | 
    
         
            -
            date:  
     | 
| 
      
 13 
     | 
    
         
            +
            date: 2012-01-12 00:00:00 Z
         
     | 
| 
       14 
14 
     | 
    
         
             
            dependencies: 
         
     | 
| 
       15 
15 
     | 
    
         
             
              - !ruby/object:Gem::Dependency 
         
     | 
| 
       16 
16 
     | 
    
         
             
                name: awesome_print
         
     |