This commit is contained in:
Robert Vokac 2024-12-17 12:43:28 +01:00
parent f7e2ad7227
commit 97a9ae2462
Signed by: robertvokac
GPG Key ID: FB9CE8E20AADA55F
12 changed files with 221 additions and 6 deletions

View File

@ -0,0 +1,24 @@
/*
* Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license
* Click nbfs://nbhost/SystemFileSystem/Templates/Classes/Class.java to edit this template
*/
package com.openeggbert.jdotnet.JDotNet;
import lombok.Getter;
import lombok.Setter;
/**
*
* @author robertvokac
*/
public class Pair<A,B> {
@Getter @Setter
private A value1;
@Getter @Setter
private B value2;
public Pair(A value1, B value2) {
this.value1 = value1;
this.value2 = value2;
}
}

View File

@ -0,0 +1,22 @@
/*
* Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license
* Click nbfs://nbhost/SystemFileSystem/Templates/Classes/Class.java to edit this template
*/
package com.openeggbert.jdotnet.JDotNet;
import java.lang.annotation.ElementType;
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.lang.annotation.Target;
/**
*
* @author robertvokac
*/
@Retention(RetentionPolicy.RUNTIME)
@Target(ElementType.TYPE_USE)
@AdditionalClassForDotNetSimulation
public @interface UnusedCode {
String description() default "";
}

View File

@ -0,0 +1,16 @@
/*
* Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license
* Click nbfs://nbhost/SystemFileSystem/Templates/Classes/Class.java to edit this template
*/
package com.openeggbert.jdotnet.System.Diagnostics;
/**
*
* @author robertvokac
*/
public class Debug {
public static void Write(String msg) {
//todo
}
}

View File

@ -8,6 +8,8 @@ package com.openeggbert.jdotnet.System;
*
* @author robertvokac
*/
public class NetException extends RuntimeException {
public class Environment {
public static void Exit(int exitStatusCode) {
//todo
}
}

View File

@ -4,14 +4,16 @@
*/
package com.openeggbert.jdotnet.System;
import lombok.AllArgsConstructor;
/**
*
* @author robertvokac
*/
public class NetRandom {
public int Next(int i) {
throw new UnsupportedOperationException("Not supported yet."); // Generated from nbfs://nbhost/SystemFileSystem/Templates/Classes/Code/GeneratedMethodBody
@AllArgsConstructor
public class Exception_ extends RuntimeException {
public Exception_(String msg) {
super(msg);
}
}

View File

@ -0,0 +1,21 @@
/*
* Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license
* Click nbfs://nbhost/SystemFileSystem/Templates/Classes/Class.java to edit this template
*/
package com.openeggbert.jdotnet.System.Globalization;
import lombok.Getter;
/**
*
* @author robertvokac
*/
public class CultureInfo {
public static CultureInfo getCurrentCulture() {
//todo
return null;
}
@Getter
private String TwoLetterISOLanguageName;
}

View File

@ -0,0 +1,15 @@
/*
* Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license
* Click nbfs://nbhost/SystemFileSystem/Templates/Classes/Class.java to edit this template
*/
package com.openeggbert.jdotnet.System.IO;
/**
*
* @author robertvokac
*/
public class Stream {
public void Close() {
//todo
}
}

View File

@ -0,0 +1,19 @@
/*
* Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license
* Click nbfs://nbhost/SystemFileSystem/Templates/Classes/Class.java to edit this template
*/
package com.openeggbert.jdotnet.System.IO;
/**
*
* @author robertvokac
*/
public class StreamReader {
public StreamReader(Stream stream) {
}
public String ReadToEnd() {
return "";//todo
}
}

View File

@ -0,0 +1,49 @@
/*
* Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license
* Click nbfs://nbhost/SystemFileSystem/Templates/Classes/Class.java to edit this template
*/
package com.openeggbert.jdotnet.System;
/**
*
* @author robertvokac
*/
public class Math_ {
private Math_() {
//Not meant to be instantiated.
}
public static final double PI = Math.PI;
public static int Min(int a, int b) {
return Math.min(a, b);
}
public static int Max(int a, int b) {
return Math.max(a, b);
}
public static double Min(double a, double b) {
return Math.min(a, b);
}
public static double Max(double a, double b) {
return Math.max(a, b);
}
public static double Cos(double a) {
return Math.cos(a);
}
public static double Sin(double a) {
return Math.sin(a);
}
public static int Abs(int a) {
return Math.abs(a);
}
public static double Abs(double a) {
return Math.abs(a);
}
public static double Pow(double a, double b) {
return Math.pow(a, b);
}
}

View File

@ -0,0 +1,22 @@
/*
* Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license
* Click nbfs://nbhost/SystemFileSystem/Templates/Classes/Class.java to edit this template
*/
package com.openeggbert.jdotnet.System;
/**
*
* @author robertvokac
*/
public class Random_ {
public int Next() {
throw new UnsupportedOperationException("Not supported yet."); // Generated from nbfs://nbhost/SystemFileSystem/Templates/Classes/Code/GeneratedMethodBody
}
public int Next(int i) {
throw new UnsupportedOperationException("Not supported yet."); // Generated from nbfs://nbhost/SystemFileSystem/Templates/Classes/Code/GeneratedMethodBody
}
public int Next(int i, int j) {
throw new UnsupportedOperationException("Not supported yet."); // Generated from nbfs://nbhost/SystemFileSystem/Templates/Classes/Code/GeneratedMethodBody
}
}

View File

@ -0,0 +1,19 @@
/*
* Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license
* Click nbfs://nbhost/SystemFileSystem/Templates/Classes/Class.java to edit this template
*/
package com.openeggbert.jdotnet.System;
/**
*
* @author robertvokac
*/
public class String_ {
private String_() {
//Not meant to be instantiated.
}
public static boolean IsNullOrEmpty(String string) {
return string == null || string.isEmpty();
}
}

View File

@ -14,4 +14,8 @@ import com.openeggbert.jdotnet.JDotNet.AdditionalClassForDotNetSimulation;
@AdditionalClassForDotNetSimulation
public abstract class Struct<T> {
public abstract T copy();
/**
* Sets this class to its default values.
*/
public abstract T reset();
}