Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions eng/versioning/version_client.txt
Original file line number Diff line number Diff line change
Expand Up @@ -461,6 +461,8 @@ com.azure.tools:azure-sdk-build-tool;1.0.0;1.1.0-beta.1
# In the pom, the version update tag after the version should name the unreleased package and the dependency version:
# <!-- {x-version-update;unreleased_com.azure:azure-core;dependency} -->

unreleased_com.azure:azure-xml;1.0.0-beta.4
unreleased_com.azure:azure-core;1.48.0-beta.1

# Released Beta dependencies: Copy the entry from above, prepend "beta_", remove the current
# version and set the version to the released beta. Released beta dependencies are only valid
Expand Down
2 changes: 1 addition & 1 deletion sdk/core/azure-core-experimental/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@
<dependency>
<groupId>com.azure</groupId>
<artifactId>azure-xml</artifactId>
<version>1.0.0-beta.3</version> <!-- {x-version-update;com.azure:azure-xml;dependency} -->
<version>1.0.0-beta.4</version> <!-- {x-version-update;unreleased_com.azure:azure-xml;dependency} -->
<scope>test</scope>
</dependency>
<dependency>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -58,17 +58,23 @@ public final class ReflectionSerializable {
try {
xmlSerializable = Class.forName("com.azure.xml.XmlSerializable");
xmlReader = Class.forName("com.azure.xml.XmlReader");

Class<?> xmlProviders = Class.forName("com.azure.xml.XmlProviders");

xmlReaderCreator = ReflectionUtils.getMethodInvoker(xmlProviders,
xmlProviders.getDeclaredMethod("createReader", byte[].class));

xmlWriterCreator = ReflectionUtils.getMethodInvoker(xmlProviders,
xmlProviders.getDeclaredMethod("createWriter", OutputStream.class));

Class<?> xmlWriter = Class.forName("com.azure.xml.XmlWriter");

try {
Class<?> xmlProviders = Class.forName("com.azure.xml.XmlProviders");

xmlReaderCreator = ReflectionUtils.getMethodInvoker(xmlProviders,
xmlProviders.getDeclaredMethod("createReader", byte[].class));

xmlWriterCreator = ReflectionUtils.getMethodInvoker(xmlProviders,
xmlProviders.getDeclaredMethod("createWriter", OutputStream.class));
} catch (LinkageError | ReflectiveOperationException ex) {
xmlReaderCreator = ReflectionUtils.getMethodInvoker(xmlReader,
xmlReader.getDeclaredMethod("fromBytes", byte[].class));
xmlWriterCreator = ReflectionUtils.getMethodInvoker(xmlWriter,
xmlWriter.getDeclaredMethod("toStream", OutputStream.class));
}

xmlWriterWriteStartDocument
= ReflectionUtils.getMethodInvoker(xmlWriter, xmlWriter.getDeclaredMethod("writeStartDocument"));

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,10 @@
*/
public final class DefaultJsonProvider implements JsonProvider {
private static final String JSON_READER_EXCEPTION
= "Both 'json' and 'options' must be passed as non-null to " + "create an instance of JsonReader.";
= "Both 'json' and 'options' must be passed as non-null to create an instance of JsonReader.";

private static final String JSON_WRITER_EXCEPTION
= "Both 'json' and 'options' must be passed as non-null to " + "create an instance of JsonWriter.";
= "Both 'json' and 'options' must be passed as non-null to create an instance of JsonWriter.";

@Override
public JsonReader createReader(byte[] json, JsonOptions options) throws IOException {
Expand Down
2 changes: 1 addition & 1 deletion sdk/serialization/azure-xml/spotbugs-exclude.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,6 @@
xsi:schemaLocation="https://github.com/spotbugs/filter/3.0.0 https://raw.githubusercontent.com/spotbugs/spotbugs/3.1.0/spotbugs/etc/findbugsfilter.xsd">
<Match>
<Bug pattern="XXE_XMLSTREAMREADER" />
<Class name="com.azure.xml.implementation.DefaultXmlReader" />
<Class name="com.azure.xml.XmlReader" />
</Match>
</FindBugsFilter>

This file was deleted.

Loading