mirror of
https://github.com/Kingsrook/qqq.git
synced 2025-07-18 05:01:07 +00:00
QQQ-14 Checkstyle cleanup
This commit is contained in:
@ -46,6 +46,7 @@
|
||||
-->
|
||||
|
||||
<module name="TreeWalker">
|
||||
<module name="SuppressWarningsHolder"/>
|
||||
<module name="OuterTypeFilename"/>
|
||||
<module name="IllegalTokenText">
|
||||
<property name="tokens" value="STRING_LITERAL, CHAR_LITERAL"/>
|
||||
@ -171,7 +172,7 @@
|
||||
<property name="caseIndent" value="3"/>
|
||||
<property name="throwsIndent" value="6"/>
|
||||
<property name="lineWrappingIndentation" value="3"/>
|
||||
<property name="arrayInitIndent" value="2"/>
|
||||
<property name="arrayInitIndent" value="6"/>
|
||||
</module>
|
||||
<!--
|
||||
<module name="AbbreviationAsWordInName">
|
||||
@ -260,4 +261,5 @@
|
||||
<module name="MissingOverride"/>
|
||||
|
||||
</module>
|
||||
<module name="SuppressWarningsFilter"/>
|
||||
</module>
|
||||
|
@ -59,18 +59,6 @@ public abstract class QTableBackendDetails
|
||||
|
||||
|
||||
|
||||
/*******************************************************************************
|
||||
** Fluent Setter for backendType
|
||||
**
|
||||
*******************************************************************************/
|
||||
public QTableBackendDetails withBackendType(String backendType)
|
||||
{
|
||||
this.backendType = backendType;
|
||||
return (this);
|
||||
}
|
||||
|
||||
|
||||
|
||||
/*******************************************************************************
|
||||
** Setter for backendType
|
||||
**
|
||||
@ -88,6 +76,20 @@ public abstract class QTableBackendDetails
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
/*******************************************************************************
|
||||
** Fluent Setter for backendType
|
||||
**
|
||||
*******************************************************************************/
|
||||
public QTableBackendDetails withBackendType(String backendType)
|
||||
{
|
||||
this.backendType = backendType;
|
||||
return (this);
|
||||
}
|
||||
|
||||
|
||||
|
||||
/*******************************************************************************
|
||||
** Fluent Setter for backendType
|
||||
**
|
||||
@ -98,6 +100,4 @@ public abstract class QTableBackendDetails
|
||||
return (this);
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
@ -81,15 +81,15 @@ public class DeserializerUtils
|
||||
/*******************************************************************************
|
||||
**
|
||||
*******************************************************************************/
|
||||
public static <T> T reflectivelyDeserialize(Class<T> _class, TreeNode treeNode) throws IOException
|
||||
public static <T> T reflectivelyDeserialize(Class<T> outputClass, TreeNode treeNode) throws IOException
|
||||
{
|
||||
try
|
||||
{
|
||||
T output = _class.getConstructor().newInstance();
|
||||
System.out.println("Reflectively deserializing a: " + _class.getName());
|
||||
T output = outputClass.getConstructor().newInstance();
|
||||
System.out.println("Reflectively deserializing a: " + outputClass.getName());
|
||||
|
||||
Map<String, Consumer<String>> setterMap = new HashMap<>();
|
||||
for(Method method : _class.getMethods())
|
||||
for(Method method : outputClass.getMethods())
|
||||
{
|
||||
if(method.getName().startsWith("set") && method.getParameterTypes().length == 1)
|
||||
{
|
||||
@ -131,7 +131,7 @@ public class DeserializerUtils
|
||||
////////////////////////////////////////////////////////////////////////
|
||||
// if we hit this, we might want to add an else-if to handle the type //
|
||||
////////////////////////////////////////////////////////////////////////
|
||||
throw (new RuntimeException("Field " + fieldName + " is of an unhandled type " + parameterType.getName() + " when deserializing " + _class.getName()));
|
||||
throw (new RuntimeException("Field " + fieldName + " is of an unhandled type " + parameterType.getName() + " when deserializing " + outputClass.getName()));
|
||||
}
|
||||
else
|
||||
{
|
||||
|
@ -82,6 +82,7 @@ public class MockQueryAction implements QueryInterface
|
||||
** Get a mock value to use, based on its type.
|
||||
**
|
||||
*******************************************************************************/
|
||||
@SuppressWarnings("checkstyle:MagicNumber")
|
||||
private Serializable getValue(QTableMetaData table, String field)
|
||||
{
|
||||
// @formatter:off // IJ can't do new-style switch correctly yet...
|
||||
|
Reference in New Issue
Block a user