Skip to content

Files

Latest commit

 

History

History
27 lines (18 loc) · 963 Bytes

IllegalImports.md

File metadata and controls

27 lines (18 loc) · 963 Bytes

Pattern: Import from illegal package

Issue: -

Description

Avoid importing from package that contains internal APIs: they are subject to change in a undocumented or unsupported way and they are bound to a specific JRE/JDK (e.g. Sun), limiting portability of your programs.

Prefer a public, documented and specified class instead.

Parameters

NameDescriptionTypeDefault Value
illegalImports Illegal Imports string sun._,java.awt._

Example configuration

<check enabled="true" class="org.scalastyle.scalariform.IllegalImportsChecker" level="warning"/>