Package org.springframework.orm.jpa.persistenceunit

# Class PersistenceManagedTypesScanner

java.lang.Object
org.springframework.orm.jpa.persistenceunit.PersistenceManagedTypesScanner

public final class PersistenceManagedTypesScanner extends Object
Scanner of `PersistenceManagedTypes`.

Since:
  6.0
Author:
  Stephane Nicoll

## Constructor Summary

Constructors
Constructor
Description
`PersistenceManagedTypesScanner(org.springframework.core.io.ResourceLoader resourceLoader)`
Create a new `PersistenceManagedTypesScanner` for the given resource loader.
`PersistenceManagedTypesScanner(org.springframework.core.io.ResourceLoader resourceLoader, ManagedClassNameFilter managedClassNameFilter)`
Create a new `PersistenceManagedTypesScanner` for the given resource loader.

## Method Summary

Modifier and Type
Method
Description
`PersistenceManagedTypes`
`scan(String... packagesToScan)`
Scan the specified packages and return a `PersistenceManagedTypes` that represents the result of the scanning.

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

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

## Constructor Details

### PersistenceManagedTypesScanner

public PersistenceManagedTypesScanner(org.springframework.core.io.ResourceLoader resourceLoader)
Create a new `PersistenceManagedTypesScanner` for the given resource loader.

Parameters:
  `resourceLoader` - the `ResourceLoader` to use

### PersistenceManagedTypesScanner

public PersistenceManagedTypesScanner(org.springframework.core.io.ResourceLoader resourceLoader, @Nullable ManagedClassNameFilter managedClassNameFilter)
Create a new `PersistenceManagedTypesScanner` for the given resource loader.

Parameters:
  `resourceLoader` - the `ResourceLoader` to use
  `managedClassNameFilter` - an optional predicate to filter entity classes
Since:
  6.1.4

## Method Details

### scan

public PersistenceManagedTypes scan(String... packagesToScan)
Scan the specified packages and return a `PersistenceManagedTypes` that represents the result of the scanning.

Parameters:
  `packagesToScan` - the packages to scan
Returns:
  the `PersistenceManagedTypes` instance