[java-opensaml] branch main updated: Add missing getVersion method and deprecate the earlier variants.
Scott Cantor
cantor.2 at osu.edu
Thu Apr 6 12:53:08 UTC 2023
This is an automated email from the git hooks/post-receive script.
scantor pushed a commit to branch main
in repository java-opensaml.
View the commit online:
http://git.shibboleth.net/view/?p=java-opensaml.git;a=commit;h=7245b2e643c4e8f3bc7e66a72695516a45948390
The following commit(s) were added to refs/heads/main by this push:
new 7245b2e64 Add missing getVersion method and deprecate the earlier variants.
7245b2e64 is described below
commit 7245b2e643c4e8f3bc7e66a72695516a45948390
Author: Scott Cantor <cantor.2 at osu.edu>
AuthorDate: Thu Apr 6 08:53:05 2023 -0400
Add missing getVersion method and deprecate the earlier variants.
---
.../java/org/opensaml/saml/saml1/core/Assertion.java | 19 +++++++++++++++++++
.../opensaml/saml/saml1/core/impl/AssertionImpl.java | 5 +++++
2 files changed, 24 insertions(+)
diff --git a/opensaml-saml-api/src/main/java/org/opensaml/saml/saml1/core/Assertion.java b/opensaml-saml-api/src/main/java/org/opensaml/saml/saml1/core/Assertion.java
index 3c0ef6d9c..c3073ab29 100644
--- a/opensaml-saml-api/src/main/java/org/opensaml/saml/saml1/core/Assertion.java
+++ b/opensaml-saml-api/src/main/java/org/opensaml/saml/saml1/core/Assertion.java
@@ -90,17 +90,36 @@ public interface Assertion extends SignableSAMLObject, Evidentiary {
/**
* Get the MajorVersion attribute.
*
+ * <p>Deprecated, use {@link #getVersion()}.</p>
+ *
* @return the stored MajorVersion
+ *
+ * @deprecated
*/
+ @Deprecated(since="5.0.0", forRemoval=true)
@Nullable Integer getMajorVersion();
/**
* Get the MinorVersion attribute.
*
+ * <p>Deprecated, use {@link #getVersion()}.</p>
+ *
* @return the stored MinorVersion
+ *
+ * @deprecated
*/
+ @Deprecated(since="5.0.0", forRemoval=true)
@Nullable Integer getMinorVersion();
+ /**
+ * Gets the SAML version for this message.
+ *
+ * @return SAML version for this message
+ *
+ * @since 5.0.0
+ */
+ @Nullable SAMLVersion getVersion();
+
/**
* Set the SAML version of this assertion.
*
diff --git a/opensaml-saml-impl/src/main/java/org/opensaml/saml/saml1/core/impl/AssertionImpl.java b/opensaml-saml-impl/src/main/java/org/opensaml/saml/saml1/core/impl/AssertionImpl.java
index 6ff55c66d..9f3978956 100644
--- a/opensaml-saml-impl/src/main/java/org/opensaml/saml/saml1/core/impl/AssertionImpl.java
+++ b/opensaml-saml-impl/src/main/java/org/opensaml/saml/saml1/core/impl/AssertionImpl.java
@@ -96,6 +96,11 @@ public class AssertionImpl extends AbstractSignableSAMLObject implements Asserti
return version != null ? version.getMinorVersion() : null;
}
+ /** {@inheritDoc} */
+ @Nullable public SAMLVersion getVersion() {
+ return version;
+ }
+
/** {@inheritDoc} */
public void setVersion(@Nullable final SAMLVersion newVersion){
version = prepareForAssignment(version, newVersion);
--
To stop receiving notification emails like this one, please contact
the administrator of this repository.
More information about the commits
mailing list