当前页面:
在线文档首页 >
NetBeans API Javadoc (Current Development Version)
CodeStyle (Java Source) - NetBeans API Javadoc (Current Development Version)
org.netbeans.api.java.source
Class CodeStyle
java.lang.Object
org.netbeans.api.java.source.CodeStyle
public final class CodeStyle
- extends Object
XXX make sure the getters get the defaults from somewhere
XXX add support for profiles
XXX get the preferences node from somewhere else in odrer to be able not to
use the getters and to be able to write to it.
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
getDefault
public static CodeStyle getDefault(Project project)
expandTabToSpaces
public boolean expandTabToSpaces()
getTabSize
public int getTabSize()
getIndentSize
public int getIndentSize()
getContinuationIndentSize
public int getContinuationIndentSize()
getLabelIndent
public int getLabelIndent()
absoluteLabelIndent
public boolean absoluteLabelIndent()
indentTopLevelClassMembers
public boolean indentTopLevelClassMembers()
indentCasesFromSwitch
public boolean indentCasesFromSwitch()
getRightMargin
public int getRightMargin()
preferLongerNames
public boolean preferLongerNames()
getFieldNamePrefix
public String getFieldNamePrefix()
getFieldNameSuffix
public String getFieldNameSuffix()
getStaticFieldNamePrefix
public String getStaticFieldNamePrefix()
getStaticFieldNameSuffix
public String getStaticFieldNameSuffix()
getParameterNamePrefix
public String getParameterNamePrefix()
getParameterNameSuffix
public String getParameterNameSuffix()
getLocalVarNamePrefix
public String getLocalVarNamePrefix()
getLocalVarNameSuffix
public String getLocalVarNameSuffix()
qualifyFieldAccess
public boolean qualifyFieldAccess()
useIsForBooleanGetters
public boolean useIsForBooleanGetters()
addOverrideAnnotation
public boolean addOverrideAnnotation()
makeLocalVarsFinal
public boolean makeLocalVarsFinal()
makeParametersFinal
public boolean makeParametersFinal()
getClassDeclBracePlacement
public CodeStyle.BracePlacement getClassDeclBracePlacement()
getMethodDeclBracePlacement
public CodeStyle.BracePlacement getMethodDeclBracePlacement()
getOtherBracePlacement
public CodeStyle.BracePlacement getOtherBracePlacement()
specialElseIf
public boolean specialElseIf()
redundantIfBraces
public CodeStyle.BracesGenerationStyle redundantIfBraces()
redundantForBraces
public CodeStyle.BracesGenerationStyle redundantForBraces()
redundantWhileBraces
public CodeStyle.BracesGenerationStyle redundantWhileBraces()
redundantDoWhileBraces
public CodeStyle.BracesGenerationStyle redundantDoWhileBraces()
alignMultilineMethodParams
public boolean alignMultilineMethodParams()
alignMultilineCallArgs
public boolean alignMultilineCallArgs()
alignMultilineImplements
public boolean alignMultilineImplements()
alignMultilineThrows
public boolean alignMultilineThrows()
alignMultilineParenthesized
public boolean alignMultilineParenthesized()
alignMultilineBinaryOp
public boolean alignMultilineBinaryOp()
alignMultilineTernaryOp
public boolean alignMultilineTernaryOp()
alignMultilineAssignment
public boolean alignMultilineAssignment()
alignMultilineFor
public boolean alignMultilineFor()
alignMultilineArrayInit
public boolean alignMultilineArrayInit()
placeElseOnNewLine
public boolean placeElseOnNewLine()
placeWhileOnNewLine
public boolean placeWhileOnNewLine()
placeCatchOnNewLine
public boolean placeCatchOnNewLine()
placeFinallyOnNewLine
public boolean placeFinallyOnNewLine()
placeNewLineAfterModifiers
public boolean placeNewLineAfterModifiers()
wrapExtendsImplementsKeyword
public CodeStyle.WrapStyle wrapExtendsImplementsKeyword()
wrapExtendsImplementsList
public CodeStyle.WrapStyle wrapExtendsImplementsList()
wrapMethodParams
public CodeStyle.WrapStyle wrapMethodParams()
wrapThrowsKeyword
public CodeStyle.WrapStyle wrapThrowsKeyword()
wrapThrowsList
public CodeStyle.WrapStyle wrapThrowsList()
wrapMethodCallArgs
public CodeStyle.WrapStyle wrapMethodCallArgs()
wrapChainedMethodCalls
public CodeStyle.WrapStyle wrapChainedMethodCalls()
wrapArrayInit
public CodeStyle.WrapStyle wrapArrayInit()
wrapFor
public CodeStyle.WrapStyle wrapFor()
wrapForStatement
public CodeStyle.WrapStyle wrapForStatement()
wrapIfStatement
public CodeStyle.WrapStyle wrapIfStatement()
wrapWhileStatement
public CodeStyle.WrapStyle wrapWhileStatement()
wrapDoWhileStatement
public CodeStyle.WrapStyle wrapDoWhileStatement()
wrapAssert
public CodeStyle.WrapStyle wrapAssert()
wrapEnumConstants
public CodeStyle.WrapStyle wrapEnumConstants()
wrapAnnotations
public CodeStyle.WrapStyle wrapAnnotations()
wrapBinaryOps
public CodeStyle.WrapStyle wrapBinaryOps()
wrapTernaryOps
public CodeStyle.WrapStyle wrapTernaryOps()
wrapAssignOps
public CodeStyle.WrapStyle wrapAssignOps()
getBlankLinesBeforePackage
public int getBlankLinesBeforePackage()
getBlankLinesAfterPackage
public int getBlankLinesAfterPackage()
getBlankLinesBeforeImports
public int getBlankLinesBeforeImports()
getBlankLinesAfterImports
public int getBlankLinesAfterImports()
getBlankLinesBeforeClass
public int getBlankLinesBeforeClass()
getBlankLinesAfterClass
public int getBlankLinesAfterClass()
getBlankLinesAfterClassHeader
public int getBlankLinesAfterClassHeader()
getBlankLinesBeforeFields
public int getBlankLinesBeforeFields()
getBlankLinesAfterFields
public int getBlankLinesAfterFields()
getBlankLinesBeforeMethods
public int getBlankLinesBeforeMethods()
getBlankLinesAfterMethods
public int getBlankLinesAfterMethods()
spaceBeforeWhile
public boolean spaceBeforeWhile()
spaceBeforeElse
public boolean spaceBeforeElse()
spaceBeforeCatch
public boolean spaceBeforeCatch()
spaceBeforeFinally
public boolean spaceBeforeFinally()
spaceBeforeMethodDeclParen
public boolean spaceBeforeMethodDeclParen()
spaceBeforeMethodCallParen
public boolean spaceBeforeMethodCallParen()
spaceBeforeIfParen
public boolean spaceBeforeIfParen()
spaceBeforeForParen
public boolean spaceBeforeForParen()
spaceBeforeWhileParen
public boolean spaceBeforeWhileParen()
spaceBeforeCatchParen
public boolean spaceBeforeCatchParen()
spaceBeforeSwitchParen
public boolean spaceBeforeSwitchParen()
spaceBeforeSynchronizedParen
public boolean spaceBeforeSynchronizedParen()
spaceBeforeAnnotationParen
public boolean spaceBeforeAnnotationParen()
spaceAroundUnaryOps
public boolean spaceAroundUnaryOps()
spaceAroundBinaryOps
public boolean spaceAroundBinaryOps()
spaceAroundTernaryOps
public boolean spaceAroundTernaryOps()
spaceAroundAssignOps
public boolean spaceAroundAssignOps()
spaceBeforeClassDeclLeftBrace
public boolean spaceBeforeClassDeclLeftBrace()
spaceBeforeMethodDeclLeftBrace
public boolean spaceBeforeMethodDeclLeftBrace()
spaceBeforeIfLeftBrace
public boolean spaceBeforeIfLeftBrace()
spaceBeforeElseLeftBrace
public boolean spaceBeforeElseLeftBrace()
spaceBeforeWhileLeftBrace
public boolean spaceBeforeWhileLeftBrace()
spaceBeforeForLeftBrace
public boolean spaceBeforeForLeftBrace()
spaceBeforeDoLeftBrace
public boolean spaceBeforeDoLeftBrace()
spaceBeforeSwitchLeftBrace
public boolean spaceBeforeSwitchLeftBrace()
spaceBeforeTryLeftBrace
public boolean spaceBeforeTryLeftBrace()
spaceBeforeCatchLeftBrace
public boolean spaceBeforeCatchLeftBrace()
spaceBeforeFinallyLeftBrace
public boolean spaceBeforeFinallyLeftBrace()
spaceBeforeSynchronizedLeftBrace
public boolean spaceBeforeSynchronizedLeftBrace()
spaceBeforeStaticInitLeftBrace
public boolean spaceBeforeStaticInitLeftBrace()
spaceBeforeArrayInitLeftBrace
public boolean spaceBeforeArrayInitLeftBrace()
spaceWithinParens
public boolean spaceWithinParens()
spaceWithinMethodDeclParens
public boolean spaceWithinMethodDeclParens()
spaceWithinMethodCallParens
public boolean spaceWithinMethodCallParens()
spaceWithinIfParens
public boolean spaceWithinIfParens()
spaceWithinForParens
public boolean spaceWithinForParens()
spaceWithinWhileParens
public boolean spaceWithinWhileParens()
spaceWithinSwitchParens
public boolean spaceWithinSwitchParens()
spaceWithinCatchParens
public boolean spaceWithinCatchParens()
spaceWithinSynchronizedParens
public boolean spaceWithinSynchronizedParens()
spaceWithinTypeCastParens
public boolean spaceWithinTypeCastParens()
spaceWithinAnnotationParens
public boolean spaceWithinAnnotationParens()
spaceWithinBraces
public boolean spaceWithinBraces()
spaceWithinArrayInitBrackets
public boolean spaceWithinArrayInitBrackets()
spaceBeforeComma
public boolean spaceBeforeComma()
spaceAfterComma
public boolean spaceAfterComma()
spaceBeforeSemi
public boolean spaceBeforeSemi()
spaceAfterSemi
public boolean spaceAfterSemi()
spaceBeforeColon
public boolean spaceBeforeColon()
spaceAfterColon
public boolean spaceAfterColon()
spaceAfterTypeCast
public boolean spaceAfterTypeCast()
useSingleClassImport
public boolean useSingleClassImport()
useFQNs
public boolean useFQNs()
countForUsingStarImport
public int countForUsingStarImport()
countForUsingStaticStarImport
public int countForUsingStaticStarImport()
getPackagesForStarImport
public String[] getPackagesForStarImport()