# IJavaAppResource

- Kind: `interface`
- Package: [Aspire.Hosting.Java](/reference/api/csharp/aspire.hosting.java.md)
- Version: `13.6.0-preview.1.26478.8`
- Namespace: `Aspire.Hosting.Java`
- Target framework: `net10.0`
- Source: [GitHub](https://github.com/microsoft/aspire/blob/f4c27f2d43ddc1cacd0dd083b30d1fea1cee7a62/src/Aspire.Hosting.Java/IJavaAppResource.cs)
- Implements: `IResource`, `IResourceWithEnvironment`

Marks a resource that runs a Java application, whether as a local process or as a container.

## Definition

```csharp
namespace Aspire.Hosting.Java;

public interface IJavaAppResource
    : Aspire.Hosting.ApplicationModel.IResource,
      Aspire.Hosting.ApplicationModel.IResourceWithEnvironment
{
    // ...
}
```

## Remarks

Implemented by [JavaAppResource](/reference/api/csharp/aspire.hosting.java/javaappresource.md) and [JavaContainerResource](/reference/api/csharp/aspire.hosting.java/javacontainerresource.md) so that configuration which is meaningful for any JVM, such as [JavaHostingExtensions.WithJvmArgs(IResourceBuilder<T>, string[])](/reference/api/csharp/aspire.hosting.java/javahostingextensions/methods.md#withjvmargs-iresourcebuilder-t-string), applies to both without also appearing on unrelated executables and containers.
