Class List Method List File List

# Class: VertxWeb::StaticHandler

Inherits:
  Object
  - Object
  - VertxWeb::StaticHandler
  show all
Defined in:
  /Users/julien/java/vertx-stack/stack-docs/target/rb/vertx-web/static_handler.rb

## Class Method Summary (collapse)

- + (Object) create(root = nil)

## Instance Method Summary (collapse)

- - (Object) handle(arg0 = nil)
- - (StaticHandler) initialize(j_del) constructor
  A new instance of StaticHandler.
- - (Object) j_del
- - (Object) set_allow_root_file_system_access(allowRootFileSystemAccess = nil)
- - (Object) set_always_async_fs(alwaysAsyncFS = nil)
- - (Object) set_cache_entry_timeout(timeout = nil)
- - (Object) set_caching_enabled(enabled = nil)
- - (Object) set_directory_listing(directoryListing = nil)
- - (Object) set_directory_template(directoryTemplate = nil)
- - (Object) set_enable_fs_tuning(enableFSTuning = nil)
- - (Object) set_enable_range_support(enableRangeSupport = nil)
- - (Object) set_files_read_only(readOnly = nil)
- - (Object) set_include_hidden(includeHidden = nil)
- - (Object) set_index_page(indexPage = nil)
- - (Object) set_max_age_seconds(maxAgeSeconds = nil)
- - (Object) set_max_avg_serve_time_ns(maxAvgServeTimeNanoSeconds = nil)
- - (Object) set_max_cache_size(maxCacheSize = nil)
- - (Object) set_web_root(webRoot = nil)

## Constructor Details

### - (`StaticHandler`) initialize(j_del)

Returns a new instance of StaticHandler

    9
    10
    11
    # File '/Users/julien/java/vertx-stack/stack-docs/target/rb/vertx-web/static_handler.rb', line 9

    def initialize(j_del)
      @j_del = j_del
    end

## Class Method Details

### + (`Object`) create(root = nil)

Raises:

- (`ArgumentError`)

    28
    29
    30
    31
    32
    33
    34
    35
    # File '/Users/julien/java/vertx-stack/stack-docs/target/rb/vertx-web/static_handler.rb', line 28

    def self.create(root=nil)
      if !block_given? && root == nil
        return ::Vertx::Util::Utils.safe_create(Java::IoVertxExtWebHandler::StaticHandler.java_method(:create, []).call(),::VertxWeb::StaticHandler)
      elsif root.class == String && !block_given?
        return ::Vertx::Util::Utils.safe_create(Java::IoVertxExtWebHandler::StaticHandler.java_method(:create, [Java::java.lang.String.java_class]).call(root),::VertxWeb::StaticHandler)
      end
      raise ArgumentError, "Invalid arguments when calling create(root)"
    end

## Instance Method Details

### - (`Object`) handle(arg0 = nil)

Raises:

- (`ArgumentError`)

    19
    20
    21
    22
    23
    24
    # File '/Users/julien/java/vertx-stack/stack-docs/target/rb/vertx-web/static_handler.rb', line 19

    def handle(arg0=nil)
      if arg0.class.method_defined?(:j_del) && !block_given?
        return @j_del.java_method(:handle, [Java::IoVertxExtWeb::RoutingContext.java_class]).call(arg0.j_del)
      end
      raise ArgumentError, "Invalid arguments when calling handle(arg0)"
    end

### - (`Object`) j_del

    14
    15
    16
    # File '/Users/julien/java/vertx-stack/stack-docs/target/rb/vertx-web/static_handler.rb', line 14

    def j_del
      @j_del
    end

### - (`Object`) set_allow_root_file_system_access(allowRootFileSystemAccess = nil)

Raises:

- (`ArgumentError`)

    39
    40
    41
    42
    43
    44
    45
    # File '/Users/julien/java/vertx-stack/stack-docs/target/rb/vertx-web/static_handler.rb', line 39

    def set_allow_root_file_system_access(allowRootFileSystemAccess=nil)
      if (allowRootFileSystemAccess.class == TrueClass || allowRootFileSystemAccess.class == FalseClass) && !block_given?
        @j_del.java_method(:setAllowRootFileSystemAccess, [Java::boolean.java_class]).call(allowRootFileSystemAccess)
        return self
      end
      raise ArgumentError, "Invalid arguments when calling set_allow_root_file_system_access(allowRootFileSystemAccess)"
    end

### - (`Object`) set_always_async_fs(alwaysAsyncFS = nil)

Raises:

- (`ArgumentError`)

    139
    140
    141
    142
    143
    144
    145
    # File '/Users/julien/java/vertx-stack/stack-docs/target/rb/vertx-web/static_handler.rb', line 139

    def set_always_async_fs(alwaysAsyncFS=nil)
      if (alwaysAsyncFS.class == TrueClass || alwaysAsyncFS.class == FalseClass) && !block_given?
        @j_del.java_method(:setAlwaysAsyncFS, [Java::boolean.java_class]).call(alwaysAsyncFS)
        return self
      end
      raise ArgumentError, "Invalid arguments when calling set_always_async_fs(alwaysAsyncFS)"
    end

### - (`Object`) set_cache_entry_timeout(timeout = nil)

Raises:

- (`ArgumentError`)

    109
    110
    111
    112
    113
    114
    115
    # File '/Users/julien/java/vertx-stack/stack-docs/target/rb/vertx-web/static_handler.rb', line 109

    def set_cache_entry_timeout(timeout=nil)
      if timeout.class == Fixnum && !block_given?
        @j_del.java_method(:setCacheEntryTimeout, [Java::long.java_class]).call(timeout)
        return self
      end
      raise ArgumentError, "Invalid arguments when calling set_cache_entry_timeout(timeout)"
    end

### - (`Object`) set_caching_enabled(enabled = nil)

Raises:

- (`ArgumentError`)

    79
    80
    81
    82
    83
    84
    85
    # File '/Users/julien/java/vertx-stack/stack-docs/target/rb/vertx-web/static_handler.rb', line 79

    def set_caching_enabled(enabled=nil)
      if (enabled.class == TrueClass || enabled.class == FalseClass) && !block_given?
        @j_del.java_method(:setCachingEnabled, [Java::boolean.java_class]).call(enabled)
        return self
      end
      raise ArgumentError, "Invalid arguments when calling set_caching_enabled(enabled)"
    end

### - (`Object`) set_directory_listing(directoryListing = nil)

Raises:

- (`ArgumentError`)

    89
    90
    91
    92
    93
    94
    95
    # File '/Users/julien/java/vertx-stack/stack-docs/target/rb/vertx-web/static_handler.rb', line 89

    def set_directory_listing(directoryListing=nil)
      if (directoryListing.class == TrueClass || directoryListing.class == FalseClass) && !block_given?
        @j_del.java_method(:setDirectoryListing, [Java::boolean.java_class]).call(directoryListing)
        return self
      end
      raise ArgumentError, "Invalid arguments when calling set_directory_listing(directoryListing)"
    end

### - (`Object`) set_directory_template(directoryTemplate = nil)

Raises:

- (`ArgumentError`)

    169
    170
    171
    172
    173
    174
    175
    # File '/Users/julien/java/vertx-stack/stack-docs/target/rb/vertx-web/static_handler.rb', line 169

    def set_directory_template(directoryTemplate=nil)
      if directoryTemplate.class == String && !block_given?
        @j_del.java_method(:setDirectoryTemplate, [Java::java.lang.String.java_class]).call(directoryTemplate)
        return self
      end
      raise ArgumentError, "Invalid arguments when calling set_directory_template(directoryTemplate)"
    end

### - (`Object`) set_enable_fs_tuning(enableFSTuning = nil)

Raises:

- (`ArgumentError`)

    149
    150
    151
    152
    153
    154
    155
    # File '/Users/julien/java/vertx-stack/stack-docs/target/rb/vertx-web/static_handler.rb', line 149

    def set_enable_fs_tuning(enableFSTuning=nil)
      if (enableFSTuning.class == TrueClass || enableFSTuning.class == FalseClass) && !block_given?
        @j_del.java_method(:setEnableFSTuning, [Java::boolean.java_class]).call(enableFSTuning)
        return self
      end
      raise ArgumentError, "Invalid arguments when calling set_enable_fs_tuning(enableFSTuning)"
    end

### - (`Object`) set_enable_range_support(enableRangeSupport = nil)

Raises:

- (`ArgumentError`)

    179
    180
    181
    182
    183
    184
    185
    # File '/Users/julien/java/vertx-stack/stack-docs/target/rb/vertx-web/static_handler.rb', line 179

    def set_enable_range_support(enableRangeSupport=nil)
      if (enableRangeSupport.class == TrueClass || enableRangeSupport.class == FalseClass) && !block_given?
        @j_del.java_method(:setEnableRangeSupport, [Java::boolean.java_class]).call(enableRangeSupport)
        return self
      end
      raise ArgumentError, "Invalid arguments when calling set_enable_range_support(enableRangeSupport)"
    end

### - (`Object`) set_files_read_only(readOnly = nil)

Raises:

- (`ArgumentError`)

    59
    60
    61
    62
    63
    64
    65
    # File '/Users/julien/java/vertx-stack/stack-docs/target/rb/vertx-web/static_handler.rb', line 59

    def set_files_read_only(readOnly=nil)
      if (readOnly.class == TrueClass || readOnly.class == FalseClass) && !block_given?
        @j_del.java_method(:setFilesReadOnly, [Java::boolean.java_class]).call(readOnly)
        return self
      end
      raise ArgumentError, "Invalid arguments when calling set_files_read_only(readOnly)"
    end

### - (`Object`) set_include_hidden(includeHidden = nil)

Raises:

- (`ArgumentError`)

    99
    100
    101
    102
    103
    104
    105
    # File '/Users/julien/java/vertx-stack/stack-docs/target/rb/vertx-web/static_handler.rb', line 99

    def set_include_hidden(includeHidden=nil)
      if (includeHidden.class == TrueClass || includeHidden.class == FalseClass) && !block_given?
        @j_del.java_method(:setIncludeHidden, [Java::boolean.java_class]).call(includeHidden)
        return self
      end
      raise ArgumentError, "Invalid arguments when calling set_include_hidden(includeHidden)"
    end

### - (`Object`) set_index_page(indexPage = nil)

Raises:

- (`ArgumentError`)

    119
    120
    121
    122
    123
    124
    125
    # File '/Users/julien/java/vertx-stack/stack-docs/target/rb/vertx-web/static_handler.rb', line 119

    def set_index_page(indexPage=nil)
      if indexPage.class == String && !block_given?
        @j_del.java_method(:setIndexPage, [Java::java.lang.String.java_class]).call(indexPage)
        return self
      end
      raise ArgumentError, "Invalid arguments when calling set_index_page(indexPage)"
    end

### - (`Object`) set_max_age_seconds(maxAgeSeconds = nil)

Raises:

- (`ArgumentError`)

    69
    70
    71
    72
    73
    74
    75
    # File '/Users/julien/java/vertx-stack/stack-docs/target/rb/vertx-web/static_handler.rb', line 69

    def set_max_age_seconds(maxAgeSeconds=nil)
      if maxAgeSeconds.class == Fixnum && !block_given?
        @j_del.java_method(:setMaxAgeSeconds, [Java::long.java_class]).call(maxAgeSeconds)
        return self
      end
      raise ArgumentError, "Invalid arguments when calling set_max_age_seconds(maxAgeSeconds)"
    end

### - (`Object`) set_max_avg_serve_time_ns(maxAvgServeTimeNanoSeconds = nil)

Raises:

- (`ArgumentError`)

    159
    160
    161
    162
    163
    164
    165
    # File '/Users/julien/java/vertx-stack/stack-docs/target/rb/vertx-web/static_handler.rb', line 159

    def set_max_avg_serve_time_ns(maxAvgServeTimeNanoSeconds=nil)
      if maxAvgServeTimeNanoSeconds.class == Fixnum && !block_given?
        @j_del.java_method(:setMaxAvgServeTimeNs, [Java::long.java_class]).call(maxAvgServeTimeNanoSeconds)
        return self
      end
      raise ArgumentError, "Invalid arguments when calling set_max_avg_serve_time_ns(maxAvgServeTimeNanoSeconds)"
    end

### - (`Object`) set_max_cache_size(maxCacheSize = nil)

Raises:

- (`ArgumentError`)

    129
    130
    131
    132
    133
    134
    135
    # File '/Users/julien/java/vertx-stack/stack-docs/target/rb/vertx-web/static_handler.rb', line 129

    def set_max_cache_size(maxCacheSize=nil)
      if maxCacheSize.class == Fixnum && !block_given?
        @j_del.java_method(:setMaxCacheSize, [Java::int.java_class]).call(maxCacheSize)
        return self
      end
      raise ArgumentError, "Invalid arguments when calling set_max_cache_size(maxCacheSize)"
    end

### - (`Object`) set_web_root(webRoot = nil)

Raises:

- (`ArgumentError`)

    49
    50
    51
    52
    53
    54
    55
    # File '/Users/julien/java/vertx-stack/stack-docs/target/rb/vertx-web/static_handler.rb', line 49

    def set_web_root(webRoot=nil)
      if webRoot.class == String && !block_given?
        @j_del.java_method(:setWebRoot, [Java::java.lang.String.java_class]).call(webRoot)
        return self
      end
      raise ArgumentError, "Invalid arguments when calling set_web_root(webRoot)"
    end