Skip to content

Support wildcard on package scanning feature #314

Closed
@kazuki43zoo

Description

@kazuki43zoo

See #301 (comment).

Description

In this changes, can specify a wildcard at mybatis.type-aliases-package and mybatis.type-handlers-package property as follow:

mybatis.type-aliases-package=com.example.**.model
mybatis.type-handlers-package=com.example.*.typehandler

Solution

This feature has been supported by mybatis-spring 2.0.1.

Note

This feature does not apply to mtbatis-config.xml because this feature was supported by mybatis-spring. Therefore, following configuration is invalid.

<!-- ... -->
<typeAliases>
  <package name="com.example.**.model"/> <!-- Invalid!! -->
</typeAliases>
<!-- ... -->
<typeHandlers>
  <package name="com.example.*.typehandler"/> <!-- Invalid!! -->
</typeHandlers>
<!-- ... -->

Related Links

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions