org.codehaus.modello.model.Version.toString()方法的使用及代码示例

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

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

Version.toString介绍

暂无

代码示例

代码示例来源:origin: org.codehaus.modello/modello-core

public String toString()
{
  return toString( "", "." );
}

代码示例来源:origin: org.codehaus.modello/modello-core

public int hashCode()
{
  return toString( "", null ).hashCode();
}

代码示例来源:origin: org.codehaus.modello/modello-core

public String toString()
  {
    if ( fromVersion.equals( toVersion ) )
    {
      return fromVersion.toString( "", "." );
    }
    else if ( toVersion.equals( Version.INFINITE ) )
    {
      return fromVersion.toString( "", "." ) + "+";
    }
    else
    {
      return "[" + fromVersion.toString( "", "." ) + " => " + toVersion.toString( "", "." ) + "]";
    }
  }
}

代码示例来源:origin: org.codehaus.modello/modello-plugin-xml

public String getNamespace( Version version )
{
  String namespace = this.namespace;
  if ( version != null )
  {
    namespace = StringUtils.replace( namespace, "${version}", version.toString() );
  }
  return namespace;
}

代码示例来源:origin: org.codehaus.modello/modello-plugin-xsd

public String getNamespace( Version version )
{
  String namespace = this.namespace;
  if ( version != null )
  {
    namespace = StringUtils.replace( namespace, "${version}", version.toString() );
  }
  return namespace;
}

代码示例来源:origin: org.codehaus.modello/modello-plugin-xml

public String getSchemaLocation( Version version )
  {
    String schemaLocation = this.schemaLocation;

    if ( version != null )
    {
      schemaLocation = StringUtils.replace( schemaLocation, "${version}", version.toString() );
    }

    return schemaLocation;
  }
}

代码示例来源:origin: org.codehaus.modello/modello-plugin-xsd

public String getTargetNamespace( Version version )
  {
    String targetNamespace = this.targetNamespace;

    if ( version != null )
    {
      targetNamespace = StringUtils.replace( targetNamespace, "${version}", version.toString() );
    }

    return targetNamespace;
  }
}

代码示例来源:origin: org.codehaus.modello/modello-core

public String getDefaultPackageName( boolean withVersion, Version version )
{
  String packageName = getDefault( ModelDefault.PACKAGE ).getValue();
  if ( withVersion )
  {
    packageName += "." + version.toString( "v", "_" );
  }
  return packageName;
}

代码示例来源:origin: org.codehaus.modello/modello-core

public String getPackageName( boolean withVersion, Version version )
{
  String p;
  if ( packageName != null )
  {
    p = packageName;
  }
  else
  {
    try
    {
      p = model.getDefault( ModelDefault.PACKAGE ).getValue();
    }
    catch ( Exception e )
    {
      p = ModelDefault.PACKAGE_VALUE;
    }
  }
  if ( withVersion )
  {
    p += "." + version.toString( "v", "_" );
  }
  return p;
}

代码示例来源:origin: org.codehaus.modello/modello-plugin-xdoc

directory = new File( directory, getGeneratedVersion().toString() );

代码示例来源:origin: org.codehaus.modello/modello-plugin-jpox

private void writeModelloMetadataClass( XMLWriter writer ) throws ModelloException
{
  writer.startElement( "class" );
  writer.addAttribute( "name", getModel().getName() + "ModelloMetadata" );
  writer.addAttribute( "detachable", String.valueOf( true ) );
  writer.startElement( "field" );
  writer.addAttribute( "name", "modelVersion" );
  writer.addAttribute( "null-value", "default" );
  writer.startElement( "column" );
  writer.addAttribute( "default-value", getGeneratedVersion().toString() );
  writer.endElement(); // column
  writer.endElement(); // field
  writer.endElement(); // class
}

代码示例来源:origin: org.apache.archiva.redback.components.modello/modello-plugin-jpox

private void writeModelloMetadataClass( XMLWriter writer ) throws ModelloException
{
  writer.startElement( "class" );
  writer.addAttribute( "name", getModel().getName() + "ModelloMetadata" );
  writer.addAttribute( "detachable", String.valueOf( true ) );
  writer.startElement( "field" );
  writer.addAttribute( "name", "modelVersion" );
  writer.addAttribute( "null-value", "default" );
  writer.startElement( "column" );
  writer.addAttribute( "default-value", getGeneratedVersion().toString() );
  writer.endElement(); // column
  writer.endElement(); // field
  writer.endElement(); // class
}

代码示例来源:origin: org.codehaus.modello/modello-plugin-xsd

directory = new File( directory, getGeneratedVersion().toString() );

代码示例来源:origin: org.codehaus.modello/modello-plugin-xdoc

if ( fromVersion != null && fromVersion.greaterThan( firstVersion ) )
  w.writeMarkup( fromVersion.toString() );

代码示例来源:origin: org.codehaus.modello/modello-plugin-converters

if ( v != null )
  methodName += "_" + v.toString( "v", "_" );

相关文章