Package org.springframework.web.context.support

# Class ServletContextPropertySource

java.lang.Object
org.springframework.core.env.PropertySource<T>
org.springframework.core.env.EnumerablePropertySource<ServletContext>
org.springframework.web.context.support.ServletContextPropertySource

public class ServletContextPropertySource extends org.springframework.core.env.EnumerablePropertySource<ServletContext>
`PropertySource` that reads init parameters from a `ServletContext` object.

Since:
  3.1
Author:
  Chris Beams
See Also:
  - `ServletConfigPropertySource`

## Nested Class Summary

## Nested classes/interfaces inherited from class org.springframework.core.env.PropertySource

`org.springframework.core.env.PropertySource.StubPropertySource`

## Field Summary

### Fields inherited from class org.springframework.core.env.PropertySource

`logger, name, source`

## Constructor Summary

Constructors
Constructor
Description
`ServletContextPropertySource(String name, ServletContext servletContext)`

## Method Summary

Modifier and Type
Method
Description
`String`
`getProperty(String name)`
`String[]`
`getPropertyNames()`

### Methods inherited from class org.springframework.core.env.EnumerablePropertySource

`containsProperty`

### Methods inherited from class org.springframework.core.env.PropertySource

`equals, getName, getSource, hashCode, named, toString`

### Methods inherited from class java.lang.Object

`clone, finalize, getClass, notify, notifyAll, wait, wait, wait`

## Constructor Details

### ServletContextPropertySource

public ServletContextPropertySource(String name, ServletContext servletContext)

## Method Details

### getPropertyNames

public String[] getPropertyNames()

Specified by:
  `getPropertyNames` in class `org.springframework.core.env.EnumerablePropertySource<ServletContext>`

### getProperty

@Nullable public String getProperty(String name)

Specified by:
  `getProperty` in class `org.springframework.core.env.PropertySource<ServletContext>`