# vals **Repository Path**: mirrors_spullara/vals ## Basic Information - **Project Name**: vals - **Description**: Implement vals and lazy vals using a java agent - **Primary Language**: Unknown - **License**: Not specified - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2020-09-26 - **Last Updated**: 2025-12-21 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README When running with the Java agent, the name() method always returns the same thing and is set at the time ValsTest is initialized. ```java package spullara.vals; import org.junit.Test; import static junit.framework.Assert.assertEquals; import static spullara.vals.Vals.createVal; /** * Test making vals and lazy vals. */ public class ValsTest { public static val name() { return createVal("name" + System.currentTimeMillis()); } @Test public void test() throws InterruptedException { String first = name().get(); System.out.println(first); Thread.sleep(10); String second = name().get(); System.out.println(second); assertEquals(first, second); } } ```