mirror of
https://github.com/vanitasvitae/Smack.git
synced 2025-09-09 09:09:38 +02:00
Enable MissingJavadocPackage and UnnecessaryParentheses checkstyle checks
This commit is contained in:
parent
2ac452fe1e
commit
4ca2c7cc69
76 changed files with 120 additions and 131 deletions
|
@ -138,7 +138,7 @@ public final class CarbonManager extends Manager {
|
|||
// also reset here.
|
||||
enabled_state = false;
|
||||
boolean removed = connection().removeSyncStanzaListener(carbonsListener);
|
||||
assert (removed);
|
||||
assert removed;
|
||||
}
|
||||
@Override
|
||||
public void authenticated(XMPPConnection connection, boolean resumed) {
|
||||
|
|
|
@ -62,7 +62,7 @@ public final class EligibleForChatMarkerFilter extends StanzaExtensionFilter {
|
|||
ChatState state;
|
||||
try {
|
||||
state = ChatState.valueOf(chatStateElementName);
|
||||
return (state == ChatState.active);
|
||||
return state == ChatState.active;
|
||||
}
|
||||
catch (Exception ex) {
|
||||
return false;
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
/**
|
||||
*
|
||||
* Copyright 2017 Florian Schmaus
|
||||
* Copyright 2017-2019 Florian Schmaus
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
|
@ -22,6 +22,5 @@ public enum MessageProcessingHintType {
|
|||
no_store,
|
||||
no_copy,
|
||||
store,
|
||||
;
|
||||
|
||||
}
|
||||
|
|
|
@ -134,7 +134,7 @@ public final class HttpFileUploadManager extends Manager {
|
|||
}
|
||||
|
||||
private static UploadService uploadServiceFrom(DiscoverInfo discoverInfo) {
|
||||
assert (containsHttpFileUploadNamespace(discoverInfo));
|
||||
assert containsHttpFileUploadNamespace(discoverInfo);
|
||||
|
||||
UploadService.Version version;
|
||||
if (discoverInfo.containsFeature(NAMESPACE)) {
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
/**
|
||||
*
|
||||
* Copyright 2016 Florian Schmaus
|
||||
* Copyright 2016-2019 Florian Schmaus
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
|
@ -316,7 +316,7 @@ public final class IoTProvisioningManager extends Manager {
|
|||
return null;
|
||||
}
|
||||
Jid jid = discoverInfos.get(0).getFrom();
|
||||
assert (jid.isDomainBareJid());
|
||||
assert jid.isDomainBareJid();
|
||||
return jid.asDomainBareJid();
|
||||
}
|
||||
|
||||
|
@ -341,7 +341,7 @@ public final class IoTProvisioningManager extends Manager {
|
|||
IoTIsFriend iotIsFriend = new IoTIsFriend(friendInQuestion);
|
||||
iotIsFriend.setTo(provisioningServer);
|
||||
IoTIsFriendResponse response = connection().createStanzaCollectorAndSend(iotIsFriend).nextResultOrThrow();
|
||||
assert (response.getJid().equals(friendInQuestion));
|
||||
assert response.getJid().equals(friendInQuestion);
|
||||
boolean isFriend = response.getIsFriendResult();
|
||||
if (!isFriend) {
|
||||
// Cache the negative is friend response.
|
||||
|
|
|
@ -39,7 +39,6 @@ public class MamPrefsIQ extends IQ {
|
|||
always,
|
||||
never,
|
||||
roster,
|
||||
;
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -48,7 +48,7 @@ public class MamResultFilter extends FlexibleStanzaTypeFilter<Message> {
|
|||
}
|
||||
|
||||
String resultQueryId = mamResultExtension.getQueryId();
|
||||
return ((queryId == null && resultQueryId == null) || (queryId != null && queryId.equals(resultQueryId)));
|
||||
return (queryId == null && resultQueryId == null) || (queryId != null && queryId.equals(resultQueryId));
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -65,7 +65,7 @@ public class AbstractHttpOverXmppProviderTest {
|
|||
|
||||
IQ iq = provider.parse(parser);
|
||||
assertTrue(iq instanceof HttpOverXmppResp);
|
||||
HttpOverXmppResp body = ((HttpOverXmppResp) iq);
|
||||
HttpOverXmppResp body = (HttpOverXmppResp) iq;
|
||||
|
||||
checkHeaders(body.getHeaders(), expectedHeaders);
|
||||
}
|
||||
|
@ -85,7 +85,7 @@ public class AbstractHttpOverXmppProviderTest {
|
|||
|
||||
IQ iq = provider.parse(parser);
|
||||
assertTrue(iq instanceof HttpOverXmppReq);
|
||||
HttpOverXmppReq body = ((HttpOverXmppReq) iq);
|
||||
HttpOverXmppReq body = (HttpOverXmppReq) iq;
|
||||
|
||||
checkHeaders(body.getHeaders(), expectedHeaders);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue