javaslang.control.Validation.isValid()方法的使用及代码示例

x33g5p2x  于2022-02-01 转载在 其他  
字(2.0k)|赞(0)|评价(0)|浏览(116)

本文整理了Java中javaslang.control.Validation.isValid()方法的一些代码示例,展示了Validation.isValid()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Validation.isValid()方法的具体详情如下:
包路径:javaslang.control.Validation
类名称:Validation
方法名:isValid

Validation.isValid介绍

暂无

代码示例

代码示例来源:origin: com.io7m.smfj/io7m-smfj-format-text

this.onParseVersion(line.get());
if (v_version.isValid()) {
 final SMFFormatVersion version = v_version.get();
 super.events.onVersionReceived(version);

代码示例来源:origin: com.io7m.smfj/com.io7m.smfj.processing.main

parser_provider.schemaParserCreate(file.toUri(), stream)) {
final Validation<List<SMFErrorType>, SMFSchema> result_schema = parser.parseSchema();
if (result_schema.isValid()) {
 final SMFSchema schema = result_schema.get();
 final Validation<List<SMFErrorType>, SMFHeader> result_valid =
  validator.validate(m.header(), schema);
 if (result_valid.isValid()) {
  return valid(m);

代码示例来源:origin: com.io7m.smfj/com.io7m.smfj.validation.main

final Validation<List<SMFParseError>, SMFSchemaIdentifier> result =
 this.parseStatementIdentifier(line);
if (result.isValid()) {
 final SMFSchemaIdentifier p = result.get();
 this.received_identifier = true;
final Validation<List<SMFParseError>, SMFCoordinateSystem> result =
 this.parseStatementCoordinates(line);
if (result.isValid()) {
 builder.setRequiredCoordinateSystem(result.get());
 return errors;
final Validation<List<SMFParseError>, SMFSchemaRequireVertices> result =
 this.parseStatementRequireVertices(line);
if (result.isValid()) {
 builder.setRequireVertices(result.get());
 return errors;
final Validation<List<SMFParseError>, SMFSchemaRequireTriangles> result =
 this.parseStatementRequireTriangles(line);
if (result.isValid()) {
 builder.setRequireTriangles(result.get());
 return errors;
final Validation<List<SMFParseError>, Tuple2<Boolean, SMFSchemaAttribute>> result =
 this.parseStatementAttribute(line);
if (result.isValid()) {
 final Tuple2<Boolean, SMFSchemaAttribute> p = result.get();
 final boolean required = p._1.booleanValue();

相关文章