public class

Location

extends Object
java.lang.Object
   ↳ org.springframework.beans.factory.parsing.Location

Class Overview

Class that models an arbitrary location in a resource.

Typically used to track the location of problematic or erroneous metadata in XML configuration files. For example, a source location might be 'The bean defined on line 76 of beans.properties has an invalid Class'; another source might be the actual DOM Element from a parsed XML Document; or the source object might simply be null.

Summary

Public Constructors
Location(Resource resource)
Create a new instance of the Location class.
Location(Resource resource, Object source)
Create a new instance of the Location class.
Public Methods
Resource getResource()
Get the resource with which this location is associated.
Object getSource()
Get the actual location within the associated resource (may be null).
[Expand]
Inherited Methods
From class java.lang.Object

Public Constructors

public Location (Resource resource)

Create a new instance of the Location class.

Parameters
resource the resource with which this location is associated

public Location (Resource resource, Object source)

Create a new instance of the Location class.

Parameters
resource the resource with which this location is associated
source the actual location within the associated resource (may be null)

Public Methods

public Resource getResource ()

Also: SpringBeans

Get the resource with which this location is associated.

public Object getSource ()

Also: SpringBeans

Get the actual location within the associated resource (may be null).

See the class level javadoc for this class for examples of what the actual type of the returned object may be.