Tabnine Logo
QualifiedName.getLocalPart
Code IndexAdd Tabnine to your IDE (free)

How to use
getLocalPart
method
in
org.openprovenance.prov.model.QualifiedName

Best Java code snippets using org.openprovenance.prov.model.QualifiedName.getLocalPart (Showing top 20 results out of 315)

origin: org.openprovenance.prov/prov-template

public MethodSpec generateAttMutator(QualifiedName v, Class typ) {
  final String local=v.getLocalPart();
  final String localCamel= camelcase(local);
  MethodSpec method = MethodSpec.methodBuilder("add" + localCamel)
      .addModifiers(Modifier.PUBLIC)
      .returns(void.class)
      .addParameter(typ, "arg")
      .addStatement("bindings.addAttribute($S,arg)",local)
      .build();
  
  return method;
}

origin: org.openprovenance.prov/prov-dot

public HashMap<String, String> addURL(QualifiedName id,
                   HashMap<String, String> properties) {
if (id!=null) properties.put("URL", id.getNamespaceURI()+id.getLocalPart());
return properties;
}
origin: org.openprovenance.prov/prov-template

public MethodSpec generateVarMutator(QualifiedName v) {
  final String local=v.getLocalPart();
  final String localCamel= camelcase(local);
  MethodSpec method = MethodSpec.methodBuilder("add" + localCamel)
      .addModifiers(Modifier.PUBLIC)
      .returns(void.class)
      .addParameter(QualifiedName.class, "arg")
      .addStatement("bindings.addVariable($S,arg)",local)
      .build();
  
  return method;
}

origin: org.openprovenance.prov/prov-dot

public String nonEmptyLocalName(QualifiedName name) {
  final String localPart = name.getLocalPart();
  if ("".equals(localPart)) {
  // we are in this case for url finishing with /
  String uri=name.getNamespaceURI();
  String label=uri.substring(0, uri.length()-1);
  int i=label.lastIndexOf("#");
  int j=label.lastIndexOf("/");
  return uri.substring(Math.max(i,j)+1, uri.length());
    } else {
  return localPart;
  }
}
origin: lucmoreau/ProvToolbox

public HashMap<String, String> addURL(QualifiedName id,
                   HashMap<String, String> properties) {
if (id!=null) properties.put("URL", id.getNamespaceURI()+id.getLocalPart());
return properties;
}
origin: lucmoreau/ProvToolbox

public MethodSpec generateVarMutator(QualifiedName v) {
  final String local=v.getLocalPart();
  final String localCamel= camelcase(local);
  MethodSpec method = MethodSpec.methodBuilder("add" + localCamel)
      .addModifiers(Modifier.PUBLIC)
      .returns(void.class)
      .addParameter(QualifiedName.class, "arg")
      .addStatement("bindings.addVariable($S,arg)",local)
      .build();
  
  return method;
}

origin: lucmoreau/ProvToolbox

public MethodSpec generateAttMutator(QualifiedName v, Class typ) {
  final String local=v.getLocalPart();
  final String localCamel= camelcase(local);
  MethodSpec method = MethodSpec.methodBuilder("add" + localCamel)
      .addModifiers(Modifier.PUBLIC)
      .returns(void.class)
      .addParameter(typ, "arg")
      .addStatement("bindings.addAttribute($S,arg)",local)
      .build();
  
  return method;
}

origin: lucmoreau/ProvToolbox

public String nonEmptyLocalName(QualifiedName name) {
  final String localPart = name.getLocalPart();
  if ("".equals(localPart)) {
  // we are in this case for url finishing with /
  String uri=name.getNamespaceURI();
  String label=uri.substring(0, uri.length()-1);
  int i=label.lastIndexOf("#");
  int j=label.lastIndexOf("/");
  return uri.substring(Math.max(i,j)+1, uri.length());
    } else {
  return localPart;
  }
}
origin: org.openprovenance.prov/prov-dot

public String getPropertyValueFromAny (Type t) {
  Object val=t.getValue();
  if (val instanceof QualifiedName) {
    QualifiedName q=(QualifiedName)val;
    return q.getNamespaceURI() + q.getLocalPart();
  } else {
      return "" +  val;
  }
}

origin: lucmoreau/ProvToolbox

public String getPropertyValueFromAny (Attribute o) {
  Object val=o.getValue();
  if (val instanceof QualifiedName) {
    QualifiedName q=(QualifiedName)val;
    return q.getNamespaceURI() + q.getLocalPart();
  } else {
      return "" +  val;
  }
}
origin: lucmoreau/ProvToolbox

public String getPropertyValueFromAny (Type t) {
  Object val=t.getValue();
  if (val instanceof QualifiedName) {
    QualifiedName q=(QualifiedName)val;
    return q.getNamespaceURI() + q.getLocalPart();
  } else {
      return "" +  val;
  }
}

origin: org.openprovenance.prov/prov-dot

public String getPropertyValueFromAny (Attribute o) {
  Object val=o.getValue();
  if (val instanceof QualifiedName) {
    QualifiedName q=(QualifiedName)val;
    return q.getNamespaceURI() + q.getLocalPart();
  } else {
      return "" +  val;
  }
}
origin: org.openprovenance.prov/prov-rdf

private QualifiedName getQualqualifiedName(QualifiedName qualifiedName)
{
  if (qualifiedName.getNamespaceURI() == "" || qualifiedName.getNamespaceURI().equals(BNODE_NS))
  {
    BNode bnode = new BNodeImpl(qualifiedName.getLocalPart());
    if (!isBNodeReferenced(bnode))
    {
      return null;
    }
    return pFactory.newQualifiedName(BNODE_NS, qualifiedName.getLocalPart(), "bnode");
  }
  return qualifiedName;
}
origin: lucmoreau/ProvToolbox

private QualifiedName getQualqualifiedName(QualifiedName qualifiedName)
{
  if (qualifiedName.getNamespaceURI() == "" || qualifiedName.getNamespaceURI().equals(BNODE_NS))
  {
    BNode bnode = new BNodeImpl(qualifiedName.getLocalPart());
    if (!isBNodeReferenced(bnode))
    {
      return null;
    }
    return pFactory.newQualifiedName(BNODE_NS, qualifiedName.getLocalPart(), "bnode");
  }
  return qualifiedName;
}
origin: lucmoreau/ProvToolbox

@Override
public URIImpl qualifiedNameToURI(QualifiedName name) {
String unescapedLocalName = qnU.unescapeProvLocalName(name.getLocalPart());
return new URIImpl(name.getNamespaceURI() + unescapedLocalName);
}
origin: lucmoreau/ProvToolbox

public String getPropertyValueWithUrl (Attribute t) {
  Object val=t.getValue();
  if (val instanceof QualifiedName) {
    QualifiedName q=(QualifiedName)val;
    return q.getPrefix() +  ":" + q.getLocalPart();
    //return "<a xlink:href='" + q.getNamespaceURI() + q.getLocalPart() + "'>" + q.getLocalPart() + "</a>";
    //return "&lt;a href=\"" + q.getPrefix() + ":" + q.getLocalPart() + "\"&gt;" + q.getLocalPart() + "&lt;/a&gt;";
  } else {
      return htmlify(""+val);
  }
}
public String getPropertyValueFromAny (Attribute o) {
origin: org.openprovenance.prov/prov-rdf

@Override
public URIImpl qualifiedNameToURI(QualifiedName name) {
String unescapedLocalName = qnU.unescapeProvLocalName(name.getLocalPart());
return new URIImpl(name.getNamespaceURI() + unescapedLocalName);
}
origin: org.openprovenance.prov/prov-dot

public String getPropertyValueWithUrl (Attribute t) {
  Object val=t.getValue();
  if (val instanceof QualifiedName) {
    QualifiedName q=(QualifiedName)val;
    return q.getPrefix() +  ":" + q.getLocalPart();
    //return "<a xlink:href='" + q.getNamespaceURI() + q.getLocalPart() + "'>" + q.getLocalPart() + "</a>";
    //return "&lt;a href=\"" + q.getPrefix() + ":" + q.getLocalPart() + "\"&gt;" + q.getLocalPart() + "&lt;/a&gt;";
  } else {
      return htmlify(""+val);
  }
}
public String getPropertyValueFromAny (Attribute o) {
origin: org.openprovenance.prov/prov-rdf

@Override
public Resource qualifiedNameToResource(QualifiedName name) {
String unescapedLocalName = qnU.unescapeProvLocalName(name.getLocalPart());
if (isBlankName(name)) {
  return new BNodeImpl(unescapedLocalName);
} else {
  return new URIImpl(name.getNamespaceURI() + unescapedLocalName);
}
}
origin: lucmoreau/ProvToolbox

@Override
public Resource qualifiedNameToResource(QualifiedName name) {
String unescapedLocalName = qnU.unescapeProvLocalName(name.getLocalPart());
if (isBlankName(name)) {
  return new BNodeImpl(unescapedLocalName);
} else {
  return new URIImpl(name.getNamespaceURI() + unescapedLocalName);
}
}
org.openprovenance.prov.modelQualifiedNamegetLocalPart

Javadoc

Get the local part of this QualifiedName.

Popular methods of QualifiedName

  • equals
  • getNamespaceURI
    Get the Namespace URI of this QualifiedName.
  • getPrefix
    Get the prefix of this Qualified Name.
  • getUri
  • toQName
    Converts this QualifiedName to a valid xsd:QName by unescaping \-characters in the local names, and
  • hashCode
    Generate the hash code for this QualifiedName. The hash code is calculated using both the Namespace

Popular in Java

  • Making http post requests using okhttp
  • getSharedPreferences (Context)
  • compareTo (BigDecimal)
  • getApplicationContext (Context)
  • Point (java.awt)
    A point representing a location in (x,y) coordinate space, specified in integer precision.
  • Window (java.awt)
    A Window object is a top-level window with no borders and no menubar. The default layout for a windo
  • MalformedURLException (java.net)
    This exception is thrown when a program attempts to create an URL from an incorrect specification.
  • BitSet (java.util)
    The BitSet class implements abit array [http://en.wikipedia.org/wiki/Bit_array]. Each element is eit
  • XPath (javax.xml.xpath)
    XPath provides access to the XPath evaluation environment and expressions. Evaluation of XPath Expr
  • Project (org.apache.tools.ant)
    Central representation of an Ant project. This class defines an Ant project with all of its targets,
  • Best IntelliJ plugins
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now