repos init.

This commit is contained in:
2024-05-15 17:52:24 +08:00
commit 478bebe66b
50 changed files with 3475 additions and 0 deletions

View File

@@ -0,0 +1,22 @@
package com.serliunx.ddns.util;
import com.serliunx.ddns.core.instance.Instance;
import com.serliunx.ddns.support.Assert;
/**
* 实例相关工具方法集合
* @author SerLiunx
* @since 1.0
*/
public final class InstanceUtils {
private InstanceUtils(){throw new UnsupportedOperationException();}
public static void validateInstance(Instance instance){
Assert.notNull(instance);
String instanceName = instance.getName();
if(instanceName == null || instanceName.isEmpty()){
throw new NullPointerException();
}
}
}