Skip to content

Instantly share code, notes, and snippets.

@ljnelson

ljnelson/TerseCdiMain.java

Last active Nov 16, 2016
Embed
What would you like to do?
/*
* Copyright 2016 Laird Nelson. Released under the terms of the MIT license: https://opensource.org/licenses/MIT
*/
package com.foobar;
import javax.enterprise.inject.se.SeContainer;
import javax.enterprise.inject.se.SeContainerInitializer;
public class Main {
public static final void main(final String[] args) throws Exception {
final SeContainerInitializer containerInitializer = SeContainerInitializer.newInstance();
assert containerInitializer != null;
try (final SeContainer container = containerInitializer.initialize()) {
assert container != null;
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment