You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@deltacloud.apache.org by lu...@apache.org on 2011/02/25 01:15:48 UTC

svn commit: r1074359 - in /incubator/deltacloud/trunk/server/lib/sinatra: accept_media_types.rb lazy_auth.rb rabbit.rb rack_driver_select.rb url_for.rb

Author: lutter
Date: Fri Feb 25 00:15:48 2011
New Revision: 1074359

URL: http://svn.apache.org/viewvc?rev=1074359&view=rev
Log:
Add license headers and clarifications for sources we didn't write

Modified:
    incubator/deltacloud/trunk/server/lib/sinatra/accept_media_types.rb
    incubator/deltacloud/trunk/server/lib/sinatra/lazy_auth.rb
    incubator/deltacloud/trunk/server/lib/sinatra/rabbit.rb
    incubator/deltacloud/trunk/server/lib/sinatra/rack_driver_select.rb
    incubator/deltacloud/trunk/server/lib/sinatra/url_for.rb

Modified: incubator/deltacloud/trunk/server/lib/sinatra/accept_media_types.rb
URL: http://svn.apache.org/viewvc/incubator/deltacloud/trunk/server/lib/sinatra/accept_media_types.rb?rev=1074359&r1=1074358&r2=1074359&view=diff
==============================================================================
--- incubator/deltacloud/trunk/server/lib/sinatra/accept_media_types.rb (original)
+++ incubator/deltacloud/trunk/server/lib/sinatra/accept_media_types.rb Fri Feb 25 00:15:48 2011
@@ -1,3 +1,29 @@
+#
+# Based on https://github.com/mynyml/rack-accept-media-types
+# Commit 3d0f38882a466cc72043
+#
+# Original license:
+# Copyright (C) 2009 Martin Aumont (mynyml)
+#
+# Permission is hereby granted, free of charge, to any person obtaining a
+# copy of this software and associated documentation files (the
+# "Software"), to deal in the Software without restriction, including
+# without limitation the rights to use, copy, modify, merge, publish,
+# distribute, sublicense, and/or sell copies of the Software, and to permit
+# persons to whom the Software is furnished to do so, subject to the
+# following conditions:
+#
+# The above copyright notice and this permission notice shall be included
+# in all copies or substantial portions of the Software.
+#
+# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
+# OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
+# NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
+# DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
+# OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
+# USE OR OTHER DEALINGS IN THE SOFTWARE.
+
 module Rack
   class Request
     # The media types of the HTTP_ACCEPT header ordered according to their

Modified: incubator/deltacloud/trunk/server/lib/sinatra/lazy_auth.rb
URL: http://svn.apache.org/viewvc/incubator/deltacloud/trunk/server/lib/sinatra/lazy_auth.rb?rev=1074359&r1=1074358&r2=1074359&view=diff
==============================================================================
--- incubator/deltacloud/trunk/server/lib/sinatra/lazy_auth.rb (original)
+++ incubator/deltacloud/trunk/server/lib/sinatra/lazy_auth.rb Fri Feb 25 00:15:48 2011
@@ -1,3 +1,21 @@
+#
+# Copyright (C) 2009-2011  Red Hat, Inc.
+#
+# 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.
+
 require 'sinatra/base'
 
 # Lazy Basic HTTP authentication. Authentication is only forced when the

Modified: incubator/deltacloud/trunk/server/lib/sinatra/rabbit.rb
URL: http://svn.apache.org/viewvc/incubator/deltacloud/trunk/server/lib/sinatra/rabbit.rb?rev=1074359&r1=1074358&r2=1074359&view=diff
==============================================================================
--- incubator/deltacloud/trunk/server/lib/sinatra/rabbit.rb (original)
+++ incubator/deltacloud/trunk/server/lib/sinatra/rabbit.rb Fri Feb 25 00:15:48 2011
@@ -1,3 +1,21 @@
+#
+# Copyright (C) 2009-2011  Red Hat, Inc.
+#
+# 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.
+
 require 'sinatra/base'
 require 'sinatra/url_for'
 require 'deltacloud/validation'
@@ -66,10 +84,10 @@ module Sinatra
       def generate_options
         current_operation = self
         ::Sinatra::Application.options("/api/#{current_operation.collection.name}/#{current_operation.name}") do
-          required_params = current_operation.effective_params(driver).collect do |name, validation| 
+          required_params = current_operation.effective_params(driver).collect do |name, validation|
             name.to_s if validation.type.eql?(:required)
           end.compact.join(',')
-          optional_params = current_operation.effective_params(driver).collect do |name, validation| 
+          optional_params = current_operation.effective_params(driver).collect do |name, validation|
             name.to_s if validation.type.eql?(:optional)
           end.compact.join(',')
           headers 'X-Required-Parameters' => required_params
@@ -337,4 +355,3 @@ configure do
   end
   Sinatra::Delegator.delegate :options
 end
-

Modified: incubator/deltacloud/trunk/server/lib/sinatra/rack_driver_select.rb
URL: http://svn.apache.org/viewvc/incubator/deltacloud/trunk/server/lib/sinatra/rack_driver_select.rb?rev=1074359&r1=1074358&r2=1074359&view=diff
==============================================================================
--- incubator/deltacloud/trunk/server/lib/sinatra/rack_driver_select.rb (original)
+++ incubator/deltacloud/trunk/server/lib/sinatra/rack_driver_select.rb Fri Feb 25 00:15:48 2011
@@ -1,3 +1,21 @@
+#
+# Copyright (C) 2010-2011  Red Hat, Inc.
+#
+# 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 Rack
   class DriverSelect
 
@@ -10,7 +28,7 @@ module Rack
       'HTTP_X_DELTACLOUD_DRIVER' => :driver,
       'HTTP_X_DELTACLOUD_PROVIDER' => :provider
     }
-    
+
     def call(env)
       original_settings = { }
       HEADER_TO_ENV_MAP.each do |header, name|

Modified: incubator/deltacloud/trunk/server/lib/sinatra/url_for.rb
URL: http://svn.apache.org/viewvc/incubator/deltacloud/trunk/server/lib/sinatra/url_for.rb?rev=1074359&r1=1074358&r2=1074359&view=diff
==============================================================================
--- incubator/deltacloud/trunk/server/lib/sinatra/url_for.rb (original)
+++ incubator/deltacloud/trunk/server/lib/sinatra/url_for.rb Fri Feb 25 00:15:48 2011
@@ -1,3 +1,29 @@
+#
+# Based on https://github.com/emk/sinatra-url-for/
+# Commit 1df339284203f8f6ed8d
+#
+# Original license:
+# Copyright (C) 2009 Eric Kidd
+#
+# Permission is hereby granted, free of charge, to any person obtaining a
+# copy of this software and associated documentation files (the
+# "Software"), to deal in the Software without restriction, including
+# without limitation the rights to use, copy, modify, merge, publish,
+# distribute, sublicense, and/or sell copies of the Software, and to permit
+# persons to whom the Software is furnished to do so, subject to the
+# following conditions:
+#
+# The above copyright notice and this permission notice shall be included
+# in all copies or substantial portions of the Software.
+#
+# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
+# OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
+# NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
+# DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
+# OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
+# USE OR OTHER DEALINGS IN THE SOFTWARE.
+
 require 'uri'
 
 module Sinatra