Skip to content
Commits on Source (2)
......@@ -10,6 +10,7 @@
<attributes>
<attribute name="optional" value="true"/>
<attribute name="maven.pomderived" value="true"/>
<attribute name="test" value="true"/>
</attributes>
</classpathentry>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.6">
......
......@@ -7,8 +7,11 @@ org.eclipse.jdt.core.compiler.debug.lineNumber=generate
org.eclipse.jdt.core.compiler.debug.localVariable=generate
org.eclipse.jdt.core.compiler.debug.sourceFile=generate
org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
org.eclipse.jdt.core.compiler.problem.enablePreviewFeatures=disabled
org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
org.eclipse.jdt.core.compiler.problem.forbiddenReference=warning
org.eclipse.jdt.core.compiler.problem.reportPreviewFeatures=ignore
org.eclipse.jdt.core.compiler.release=disabled
org.eclipse.jdt.core.compiler.source=1.6
org.eclipse.jdt.core.formatter.align_type_members_on_columns=false
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=16
......
......@@ -2,7 +2,7 @@
<modelVersion>4.0.0</modelVersion>
<groupId>fr.gaellalire.vestige</groupId>
<artifactId>vestige.spi.resolver</artifactId>
<version>2.3-SNAPSHOT</version>
<version>3.0</version>
<packaging>jar</packaging>
<name>Vestige :: SPI :: Resolver</name>
<build>
......@@ -231,7 +231,7 @@
<scm>
<connection>scm:git:git@gaellalire.fr:gaellalire/vestige.spi.resolver.git</connection>
<developerConnection>scm:git:git@gaellalire.fr:gaellalire/vestige.spi.resolver.git</developerConnection>
<tag>HEAD</tag>
<tag>vestige.spi.resolver-3.0</tag>
</scm>
<reporting>
<plugins>
......
......@@ -16,6 +16,8 @@
package fr.gaellalire.vestige.spi.resolver;
import java.util.Enumeration;
/**
* @author Gael Lalire
*/
......@@ -31,4 +33,9 @@ public interface AttachableClassLoader {
*/
void addSoftReferenceObject(Object object);
/**
* @since 3.0
*/
Enumeration<? extends VestigeJar> getVestigeJarEnumeration();
}
/*
* Copyright 2021 The Apache Software Foundation.
*
* 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.
*/
package fr.gaellalire.vestige.spi.resolver;
/**
* @author Gael Lalire
*/
public interface PartiallyVerifiedAttachment {
AttachedClassLoader getAttachedClassLoader();
boolean isComplete();
String getUsedVerificationMetadata();
String getRemainingVerificationMetadata();
}
......@@ -20,7 +20,6 @@ import java.io.IOException;
import java.io.ObjectOutputStream;
import java.security.Permission;
import java.util.Collection;
import java.util.Enumeration;
/**
* @author Gael Lalire
......@@ -40,15 +39,16 @@ public interface ResolvedClassLoaderConfiguration {
boolean isAttachmentScoped();
/**
* @since 2.0
* @param verificationMetadata verification metadata you can get with {@link #createVerificationMetadata(String)}.
* @since 2.1
*/
Enumeration<? extends VestigeJar> getVestigeJarEnumeration();
AttachedClassLoader verifiedAttach(String verificationMetadata) throws ResolverException, InterruptedException;
/**
* @param verificationMetadata verification metadata you can get with {@link #createVerificationMetadata(String)}.
* @since 2.1
* @since 3.0
*/
AttachedClassLoader verifiedAttach(String verificationMetadata) throws ResolverException, InterruptedException;
PartiallyVerifiedAttachment partiallyVerifiedAttach(String verificationMetadata) throws ResolverException, InterruptedException;
/**
* @since 2.1
......
......@@ -19,7 +19,6 @@ package fr.gaellalire.vestige.spi.resolver;
import java.io.File;
import java.io.IOException;
import java.io.InputStream;
import java.io.ObjectOutputStream;
import java.net.URL;
import java.util.Enumeration;
import java.util.jar.Manifest;
......@@ -56,6 +55,12 @@ public interface VestigeJar {
InputStream open() throws IOException;
/**
* @since 3.0
* @return null if this jar is not patched
*/
VestigeJar getPatch();
/**
* This method should not be used in secure context as the file may be changed after its signature verification. Also it will need read permission anywhere because you don't
* know where the file is (resolver dependent).
......@@ -63,11 +68,4 @@ public interface VestigeJar {
@Deprecated
File getFile();
/**
* Save this object to objectOutputStream. You can restore it using {@link VestigeResolver#restoreSavedVestigeJar(java.io.ObjectInputStream)}. Use the resolver which was used
* to create this object initially or you may have restoration issue.
* @since 2.2
*/
void save(ObjectOutputStream objectOutputStream) throws IOException;
}
......@@ -30,11 +30,4 @@ public interface VestigeResolver {
*/
ResolvedClassLoaderConfiguration restoreSavedResolvedClassLoaderConfiguration(ObjectInputStream objectInputStream) throws IOException;
/**
* Restore a previously saved {@link VestigeJar}.
* @see VestigeJar#save(java.io.ObjectOutputStream)
* @since 2.2
*/
VestigeJar restoreSavedVestigeJar(ObjectInputStream objectInputStream) throws IOException;
}