PROTON-799: Added the Condition class to the Ruby engine APIs.
Project: http://git-wip-us.apache.org/repos/asf/qpid-proton/repo Commit: http://git-wip-us.apache.org/repos/asf/qpid-proton/commit/b2ea93bb Tree: http://git-wip-us.apache.org/repos/asf/qpid-proton/tree/b2ea93bb Diff: http://git-wip-us.apache.org/repos/asf/qpid-proton/diff/b2ea93bb Branch: refs/heads/ruby-engine-apis Commit: b2ea93bb8dd59e88bb176d6bd5917e31216e486f Parents: bd01492 Author: Darryl L. Pierce <mcpie...@gmail.com> Authored: Mon Feb 16 15:33:30 2015 -0500 Committer: Darryl L. Pierce <mcpie...@gmail.com> Committed: Wed May 20 11:34:49 2015 -0400 ---------------------------------------------------------------------- proton-c/bindings/ruby/lib/qpid_proton.rb | 1 + proton-c/bindings/ruby/lib/util/condition.rb | 45 +++++++++++++++++++++++ 2 files changed, 46 insertions(+) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/qpid-proton/blob/b2ea93bb/proton-c/bindings/ruby/lib/qpid_proton.rb ---------------------------------------------------------------------- diff --git a/proton-c/bindings/ruby/lib/qpid_proton.rb b/proton-c/bindings/ruby/lib/qpid_proton.rb index 80565dd..99d9dfc 100644 --- a/proton-c/bindings/ruby/lib/qpid_proton.rb +++ b/proton-c/bindings/ruby/lib/qpid_proton.rb @@ -34,6 +34,7 @@ require "util/version" require "util/error_handler" require "util/constants" require "util/swig_helper" +require "util/condition" require "util/engine" require "util/uuid" http://git-wip-us.apache.org/repos/asf/qpid-proton/blob/b2ea93bb/proton-c/bindings/ruby/lib/util/condition.rb ---------------------------------------------------------------------- diff --git a/proton-c/bindings/ruby/lib/util/condition.rb b/proton-c/bindings/ruby/lib/util/condition.rb new file mode 100644 index 0000000..b8fd94b --- /dev/null +++ b/proton-c/bindings/ruby/lib/util/condition.rb @@ -0,0 +1,45 @@ +#-- +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, +# software distributed under the License is distributed on an +# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +# KIND, either express or implied. See the License for the +# specific language governing permissions and limitations +# under the License. +#++ + +module Qpid::Proton::Util + + class Condition + + def initialize(name, description = nil, info = nil) + @name = name + @description = description + @info = info + end + + # @private + def to_s + "Condition(#{@name}, #{@description}, #{@info})" + end + + # @private + def ==(other) + ((other.class = self.class) && + (other.name == self.name) && + (other.description == self.description) && + (other.info == self.info)) + end + + end + +end --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscr...@qpid.apache.org For additional commands, e-mail: commits-h...@qpid.apache.org