Redleaf::BooleanQueryResult

A result from a SPARQL query that returns a yes or no answer.

Subversion Id

 $Id$

Authors

Copyright © 2008-2009, Michael Granger All rights reserved.

Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS “AS IS” AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

Constants

SVNRev

SVN Revision

SVNId

SVN Id

Public Instance Methods

each() click to toggle source

Call the block once if the query was true, yielding the true value.

    # File lib/redleaf/queryresult/boolean.rb, line 48
48:     def each # :yields: true
49:         yield( true ) if self.is_true?
50:     end
is_false?() click to toggle source

Returns true if the query result was not true.

    # File lib/redleaf/queryresult/boolean.rb, line 42
42:     def is_false?
43:         return !self.is_true?
44:     end
is_true?() click to toggle source

Returns true if the query result was true.

    # File lib/redleaf/queryresult/boolean.rb, line 36
36:     def is_true?
37:         return self.value == true
38:     end
to_bool() click to toggle source

Alias for #value

value() click to toggle source

Redleaf::BooleanQueryResult

static VALUE
rleaf_redleaf_booleanqueryresult_value( VALUE self ) 
Also aliased as: to_bool

Disabled; run with --debug to generate this.

[Validate]

Generated with the Darkfish Rdoc Generator 1.1.6.