lib/ews/soap/exchange_data_services.rb
def find_folder(opts)
      opts = opts.clone
      [:parent_folder_ids, :traversal, :folder_shape].each do |k|
        validate_param(opts, k, true)
      end

      req = build_soap! do |type, builder|
        if(type == :header)
        else
          builder.nbuild.FindFolder(:Traversal => camel_case(opts[:traversal])) {
            builder.nbuild.parent.default_namespace = @default_ns
            builder.folder_shape!(opts[:folder_shape])
            builder.restriction!(opts[:restriction]) if opts[:restriction]
            builder.parent_folder_ids!(opts[:parent_folder_ids])
          }
        end
      end
      do_soap_request(req)
    end
def find_folder(opts)
      opts = opts.clone
      [:parent_folder_ids, :traversal, :folder_shape].each do |k|
        validate_param(opts, k, true)
      end

      req = build_soap! do |type, builder|
        if(type == :header)
        else
          builder.nbuild.FindFolder(:Traversal => camel_case(opts[:traversal])) {
            builder.nbuild.parent.default_namespace = @default_ns
            builder.folder_shape!(opts[:folder_shape])
            builder.restriction!(opts[:restriction]) if opts[:restriction]
            builder.parent_folder_ids!(opts[:parent_folder_ids])
          }
        end
      end
      do_soap_request(req)
    end
Find subfolders of an identified folder
 @see http://msdn.microsoft.com/en-us/library/aa563918.aspx

 @param [Hash] opts
 @option opts [Array<Hash>] :parent_folder_ids An Array of folder id Hashes,
   either a DistinguishedFolderId (must me a Symbol) or a FolderId (String)
   [{:id => <myid>, :change_key => <ck>}, {:id => :root}]
 @option opts [String] :traversal Shallow/Deep/SoftDeleted
 @option opts [Hash] :folder_shape defines the FolderShape node
   See: http://msdn.microsoft.com/en-us/library/aa494311.aspx
 @option folder_shape [String] :base_shape IdOnly/Default/AllProperties
 @option folder_shape :additional_properties
   See: http://msdn.microsoft.com/en-us/library/aa563810.aspx
 @option opts [Hash] :restriction A well formatted restriction Hash.
 @example
   { :parent_folder_ids => [{:id => root}],
     :traversal => 'Deep',
     :folder_shape  => {:base_shape => 'Default'} }
 @todo add FractionalPageFolderView