Class SmsTemplateException
java.lang.Object
java.lang.Throwable
java.lang.Exception
java.lang.RuntimeException
cloud.opencode.base.sms.exception.SmsException
cloud.opencode.base.sms.exception.SmsTemplateException
- All Implemented Interfaces:
Serializable
SMS Template Exception
短信模板异常
Exception thrown for template-related errors.
模板相关错误时抛出的异常。
Features | 主要功能:
- Template ID and variable name tracking - 模板ID和变量名跟踪
- Factory methods for common errors - 常见错误的工厂方法
Usage Examples | 使用示例:
throw SmsTemplateException.notFound("TPL_001");
throw SmsTemplateException.variableMissing("TPL_001", "code");
Security | 安全性:
- Thread-safe: Yes (immutable after construction) - 线程安全: 是(构造后不可变)
- Since:
- JDK 25, opencode-base-sms V1.0.0
- Author:
- Leon Soo www.LeonSoo.com
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionSmsTemplateException(SmsErrorCode errorCode, String templateId) SmsTemplateException(SmsErrorCode errorCode, String templateId, String variableName) -
Method Summary
Modifier and TypeMethodDescriptionstatic SmsTemplateExceptionstatic SmsTemplateExceptionstatic SmsTemplateExceptionvariableMissing(String templateId, String variableName) Methods inherited from class SmsException
getCode, getErrorCodeMethods inherited from class Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
Constructor Details
-
SmsTemplateException
-
SmsTemplateException
-
-
Method Details
-
getTemplateId
-
getVariableName
-
notFound
-
invalid
-
variableMissing
-