From 317e391da554e0a09e210829ffc933e170572794 Mon Sep 17 00:00:00 2001 From: Florian Schmaus Date: Sat, 15 Aug 2020 14:03:57 +0200 Subject: [PATCH] Create smack-streammanagement project and move o.j.smack.sm code there --- settings.gradle | 1 + smack-streammanagement/build.gradle | 8 +++++++ .../org/jivesoftware/smack/sm/SMUtils.java | 0 .../smack/sm/StreamManagementException.java | 0 .../smack/sm/StreamManagementModule.java | 0 .../sm/StreamManagementModuleDescriptor.java | 0 .../jivesoftware/smack/sm/package-info.java | 0 .../smack/sm/packet/StreamManagement.java | 0 .../smack/sm/packet/package-info.java | 0 .../smack/sm/predicates/AfterXStanzas.java | 0 .../smack/sm/predicates/ForEveryMessage.java | 0 .../smack/sm/predicates/ForEveryStanza.java | 0 .../ForMatchingPredicateOrAfterXStanzas.java | 0 .../smack/sm/predicates/Predicate.java | 0 .../sm/predicates/ShortcutPredicates.java | 0 .../smack/sm/predicates/package-info.java | 0 .../sm/provider/ParseStreamManagement.java | 0 ...StreamManagementStreamFeatureProvider.java | 0 .../smack/sm/provider/package-info.java | 0 .../provider/ParseStreamManagementTest.java | 0 smack-tcp/build.gradle | 1 + .../{ => tcp}/OnceForThisStanza.java | 4 ++-- .../smack/sm/predicates/tcp/package-info.java | 21 +++++++++++++++++++ 23 files changed, 33 insertions(+), 2 deletions(-) create mode 100644 smack-streammanagement/build.gradle rename {smack-tcp => smack-streammanagement}/src/main/java/org/jivesoftware/smack/sm/SMUtils.java (100%) rename {smack-tcp => smack-streammanagement}/src/main/java/org/jivesoftware/smack/sm/StreamManagementException.java (100%) rename {smack-tcp => smack-streammanagement}/src/main/java/org/jivesoftware/smack/sm/StreamManagementModule.java (100%) rename {smack-tcp => smack-streammanagement}/src/main/java/org/jivesoftware/smack/sm/StreamManagementModuleDescriptor.java (100%) rename {smack-tcp => smack-streammanagement}/src/main/java/org/jivesoftware/smack/sm/package-info.java (100%) rename {smack-tcp => smack-streammanagement}/src/main/java/org/jivesoftware/smack/sm/packet/StreamManagement.java (100%) rename {smack-tcp => smack-streammanagement}/src/main/java/org/jivesoftware/smack/sm/packet/package-info.java (100%) rename {smack-tcp => smack-streammanagement}/src/main/java/org/jivesoftware/smack/sm/predicates/AfterXStanzas.java (100%) rename {smack-tcp => smack-streammanagement}/src/main/java/org/jivesoftware/smack/sm/predicates/ForEveryMessage.java (100%) rename {smack-tcp => smack-streammanagement}/src/main/java/org/jivesoftware/smack/sm/predicates/ForEveryStanza.java (100%) rename {smack-tcp => smack-streammanagement}/src/main/java/org/jivesoftware/smack/sm/predicates/ForMatchingPredicateOrAfterXStanzas.java (100%) rename {smack-tcp => smack-streammanagement}/src/main/java/org/jivesoftware/smack/sm/predicates/Predicate.java (100%) rename {smack-tcp => smack-streammanagement}/src/main/java/org/jivesoftware/smack/sm/predicates/ShortcutPredicates.java (100%) rename {smack-tcp => smack-streammanagement}/src/main/java/org/jivesoftware/smack/sm/predicates/package-info.java (100%) rename {smack-tcp => smack-streammanagement}/src/main/java/org/jivesoftware/smack/sm/provider/ParseStreamManagement.java (100%) rename {smack-tcp => smack-streammanagement}/src/main/java/org/jivesoftware/smack/sm/provider/StreamManagementStreamFeatureProvider.java (100%) rename {smack-tcp => smack-streammanagement}/src/main/java/org/jivesoftware/smack/sm/provider/package-info.java (100%) rename {smack-tcp => smack-streammanagement}/src/test/java/org/jivesoftware/smack/sm/provider/ParseStreamManagementTest.java (100%) rename smack-tcp/src/main/java/org/jivesoftware/smack/sm/predicates/{ => tcp}/OnceForThisStanza.java (95%) create mode 100644 smack-tcp/src/main/java/org/jivesoftware/smack/sm/predicates/tcp/package-info.java diff --git a/settings.gradle b/settings.gradle index 37bbbb004..875a6e88c 100644 --- a/settings.gradle +++ b/settings.gradle @@ -16,6 +16,7 @@ include 'smack-core', 'smack-resolver-javax', 'smack-sasl-javax', 'smack-sasl-provided', + 'smack-streammanagement', 'smack-legacy', 'smack-jingle-old', 'smack-bosh', diff --git a/smack-streammanagement/build.gradle b/smack-streammanagement/build.gradle new file mode 100644 index 000000000..c06c423d9 --- /dev/null +++ b/smack-streammanagement/build.gradle @@ -0,0 +1,8 @@ +description = """\ +Smack support for XMPP Stream Management (XEP-0198).""" + +dependencies { + api project(':smack-core') + + testFixturesApi(testFixtures(project(":smack-core"))) +} diff --git a/smack-tcp/src/main/java/org/jivesoftware/smack/sm/SMUtils.java b/smack-streammanagement/src/main/java/org/jivesoftware/smack/sm/SMUtils.java similarity index 100% rename from smack-tcp/src/main/java/org/jivesoftware/smack/sm/SMUtils.java rename to smack-streammanagement/src/main/java/org/jivesoftware/smack/sm/SMUtils.java diff --git a/smack-tcp/src/main/java/org/jivesoftware/smack/sm/StreamManagementException.java b/smack-streammanagement/src/main/java/org/jivesoftware/smack/sm/StreamManagementException.java similarity index 100% rename from smack-tcp/src/main/java/org/jivesoftware/smack/sm/StreamManagementException.java rename to smack-streammanagement/src/main/java/org/jivesoftware/smack/sm/StreamManagementException.java diff --git a/smack-tcp/src/main/java/org/jivesoftware/smack/sm/StreamManagementModule.java b/smack-streammanagement/src/main/java/org/jivesoftware/smack/sm/StreamManagementModule.java similarity index 100% rename from smack-tcp/src/main/java/org/jivesoftware/smack/sm/StreamManagementModule.java rename to smack-streammanagement/src/main/java/org/jivesoftware/smack/sm/StreamManagementModule.java diff --git a/smack-tcp/src/main/java/org/jivesoftware/smack/sm/StreamManagementModuleDescriptor.java b/smack-streammanagement/src/main/java/org/jivesoftware/smack/sm/StreamManagementModuleDescriptor.java similarity index 100% rename from smack-tcp/src/main/java/org/jivesoftware/smack/sm/StreamManagementModuleDescriptor.java rename to smack-streammanagement/src/main/java/org/jivesoftware/smack/sm/StreamManagementModuleDescriptor.java diff --git a/smack-tcp/src/main/java/org/jivesoftware/smack/sm/package-info.java b/smack-streammanagement/src/main/java/org/jivesoftware/smack/sm/package-info.java similarity index 100% rename from smack-tcp/src/main/java/org/jivesoftware/smack/sm/package-info.java rename to smack-streammanagement/src/main/java/org/jivesoftware/smack/sm/package-info.java diff --git a/smack-tcp/src/main/java/org/jivesoftware/smack/sm/packet/StreamManagement.java b/smack-streammanagement/src/main/java/org/jivesoftware/smack/sm/packet/StreamManagement.java similarity index 100% rename from smack-tcp/src/main/java/org/jivesoftware/smack/sm/packet/StreamManagement.java rename to smack-streammanagement/src/main/java/org/jivesoftware/smack/sm/packet/StreamManagement.java diff --git a/smack-tcp/src/main/java/org/jivesoftware/smack/sm/packet/package-info.java b/smack-streammanagement/src/main/java/org/jivesoftware/smack/sm/packet/package-info.java similarity index 100% rename from smack-tcp/src/main/java/org/jivesoftware/smack/sm/packet/package-info.java rename to smack-streammanagement/src/main/java/org/jivesoftware/smack/sm/packet/package-info.java diff --git a/smack-tcp/src/main/java/org/jivesoftware/smack/sm/predicates/AfterXStanzas.java b/smack-streammanagement/src/main/java/org/jivesoftware/smack/sm/predicates/AfterXStanzas.java similarity index 100% rename from smack-tcp/src/main/java/org/jivesoftware/smack/sm/predicates/AfterXStanzas.java rename to smack-streammanagement/src/main/java/org/jivesoftware/smack/sm/predicates/AfterXStanzas.java diff --git a/smack-tcp/src/main/java/org/jivesoftware/smack/sm/predicates/ForEveryMessage.java b/smack-streammanagement/src/main/java/org/jivesoftware/smack/sm/predicates/ForEveryMessage.java similarity index 100% rename from smack-tcp/src/main/java/org/jivesoftware/smack/sm/predicates/ForEveryMessage.java rename to smack-streammanagement/src/main/java/org/jivesoftware/smack/sm/predicates/ForEveryMessage.java diff --git a/smack-tcp/src/main/java/org/jivesoftware/smack/sm/predicates/ForEveryStanza.java b/smack-streammanagement/src/main/java/org/jivesoftware/smack/sm/predicates/ForEveryStanza.java similarity index 100% rename from smack-tcp/src/main/java/org/jivesoftware/smack/sm/predicates/ForEveryStanza.java rename to smack-streammanagement/src/main/java/org/jivesoftware/smack/sm/predicates/ForEveryStanza.java diff --git a/smack-tcp/src/main/java/org/jivesoftware/smack/sm/predicates/ForMatchingPredicateOrAfterXStanzas.java b/smack-streammanagement/src/main/java/org/jivesoftware/smack/sm/predicates/ForMatchingPredicateOrAfterXStanzas.java similarity index 100% rename from smack-tcp/src/main/java/org/jivesoftware/smack/sm/predicates/ForMatchingPredicateOrAfterXStanzas.java rename to smack-streammanagement/src/main/java/org/jivesoftware/smack/sm/predicates/ForMatchingPredicateOrAfterXStanzas.java diff --git a/smack-tcp/src/main/java/org/jivesoftware/smack/sm/predicates/Predicate.java b/smack-streammanagement/src/main/java/org/jivesoftware/smack/sm/predicates/Predicate.java similarity index 100% rename from smack-tcp/src/main/java/org/jivesoftware/smack/sm/predicates/Predicate.java rename to smack-streammanagement/src/main/java/org/jivesoftware/smack/sm/predicates/Predicate.java diff --git a/smack-tcp/src/main/java/org/jivesoftware/smack/sm/predicates/ShortcutPredicates.java b/smack-streammanagement/src/main/java/org/jivesoftware/smack/sm/predicates/ShortcutPredicates.java similarity index 100% rename from smack-tcp/src/main/java/org/jivesoftware/smack/sm/predicates/ShortcutPredicates.java rename to smack-streammanagement/src/main/java/org/jivesoftware/smack/sm/predicates/ShortcutPredicates.java diff --git a/smack-tcp/src/main/java/org/jivesoftware/smack/sm/predicates/package-info.java b/smack-streammanagement/src/main/java/org/jivesoftware/smack/sm/predicates/package-info.java similarity index 100% rename from smack-tcp/src/main/java/org/jivesoftware/smack/sm/predicates/package-info.java rename to smack-streammanagement/src/main/java/org/jivesoftware/smack/sm/predicates/package-info.java diff --git a/smack-tcp/src/main/java/org/jivesoftware/smack/sm/provider/ParseStreamManagement.java b/smack-streammanagement/src/main/java/org/jivesoftware/smack/sm/provider/ParseStreamManagement.java similarity index 100% rename from smack-tcp/src/main/java/org/jivesoftware/smack/sm/provider/ParseStreamManagement.java rename to smack-streammanagement/src/main/java/org/jivesoftware/smack/sm/provider/ParseStreamManagement.java diff --git a/smack-tcp/src/main/java/org/jivesoftware/smack/sm/provider/StreamManagementStreamFeatureProvider.java b/smack-streammanagement/src/main/java/org/jivesoftware/smack/sm/provider/StreamManagementStreamFeatureProvider.java similarity index 100% rename from smack-tcp/src/main/java/org/jivesoftware/smack/sm/provider/StreamManagementStreamFeatureProvider.java rename to smack-streammanagement/src/main/java/org/jivesoftware/smack/sm/provider/StreamManagementStreamFeatureProvider.java diff --git a/smack-tcp/src/main/java/org/jivesoftware/smack/sm/provider/package-info.java b/smack-streammanagement/src/main/java/org/jivesoftware/smack/sm/provider/package-info.java similarity index 100% rename from smack-tcp/src/main/java/org/jivesoftware/smack/sm/provider/package-info.java rename to smack-streammanagement/src/main/java/org/jivesoftware/smack/sm/provider/package-info.java diff --git a/smack-tcp/src/test/java/org/jivesoftware/smack/sm/provider/ParseStreamManagementTest.java b/smack-streammanagement/src/test/java/org/jivesoftware/smack/sm/provider/ParseStreamManagementTest.java similarity index 100% rename from smack-tcp/src/test/java/org/jivesoftware/smack/sm/provider/ParseStreamManagementTest.java rename to smack-streammanagement/src/test/java/org/jivesoftware/smack/sm/provider/ParseStreamManagementTest.java diff --git a/smack-tcp/build.gradle b/smack-tcp/build.gradle index 74ec76eb8..60b4b2691 100644 --- a/smack-tcp/build.gradle +++ b/smack-tcp/build.gradle @@ -3,6 +3,7 @@ Smack for standard XMPP connections over TCP.""" dependencies { compile project(':smack-core') + api project(':smack-streammanagement') testFixturesApi(testFixtures(project(":smack-core"))) } diff --git a/smack-tcp/src/main/java/org/jivesoftware/smack/sm/predicates/OnceForThisStanza.java b/smack-tcp/src/main/java/org/jivesoftware/smack/sm/predicates/tcp/OnceForThisStanza.java similarity index 95% rename from smack-tcp/src/main/java/org/jivesoftware/smack/sm/predicates/OnceForThisStanza.java rename to smack-tcp/src/main/java/org/jivesoftware/smack/sm/predicates/tcp/OnceForThisStanza.java index 94c9e6863..5c6ab7fe8 100644 --- a/smack-tcp/src/main/java/org/jivesoftware/smack/sm/predicates/OnceForThisStanza.java +++ b/smack-tcp/src/main/java/org/jivesoftware/smack/sm/predicates/tcp/OnceForThisStanza.java @@ -1,6 +1,6 @@ /** * - * Copyright © 2014 Florian Schmaus + * Copyright © 2014-2020 Florian Schmaus * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -14,7 +14,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package org.jivesoftware.smack.sm.predicates; +package org.jivesoftware.smack.sm.predicates.tcp; import org.jivesoftware.smack.filter.StanzaFilter; import org.jivesoftware.smack.packet.Stanza; diff --git a/smack-tcp/src/main/java/org/jivesoftware/smack/sm/predicates/tcp/package-info.java b/smack-tcp/src/main/java/org/jivesoftware/smack/sm/predicates/tcp/package-info.java new file mode 100644 index 000000000..15e022848 --- /dev/null +++ b/smack-tcp/src/main/java/org/jivesoftware/smack/sm/predicates/tcp/package-info.java @@ -0,0 +1,21 @@ +/** + * + * Copyright 2020 Florian Schmaus + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * XMPPTCPConnection Stream Managment Predicates. + */ +package org.jivesoftware.smack.sm.predicates.tcp;