Tabnine Logo
Descriptor.getProperty
Code IndexAdd Tabnine to your IDE (free)

How to use
getProperty
method
in
org.jflux.api.registry.Descriptor

Best Java code snippets using org.jflux.api.registry.Descriptor.getProperty (Showing top 6 results out of 315)

origin: org.jflux/org.jflux.impl.registry.osgi

/**
 * Creates an OSGi filter string from a descriptor's properties.
 * @param a the descriptor
 * @return an OSGi filter string
 */
public static String getPropertiesFilter(Descriptor a) {
  Set<String> keys = a.getPropertyKeys();
  List<String> conditions = new ArrayList<String>(keys.size());
  for(String key : a.getPropertyKeys()){
    String val = a.getProperty(key);
    String condition = format(key, val);
    conditions.add(condition);
  }
  String filter;
  if(conditions.size() > 1) {
    filter = combine(conditions);
  } else if(conditions.size() == 1) {
    filter = conditions.get(0);
  } else {
    filter = null;
  }
  return filter;
}
/**
origin: org.jflux/org.jflux.impl.registry.osgi

/**
 * Converts a descriptor into an OSGi filter string.
 * @param a the descriptor
 * @return an OSGi filter string
 */
public static String getFullFilter(Descriptor a) {
  Set<String> keys = a.getPropertyKeys();
  List<String> conditions = new ArrayList<String>(keys.size());
  for(String key : a.getPropertyKeys()){
    String val = a.getProperty(key);
    String condition = format(key, val);
    conditions.add(condition);
  }
  conditions.add(format(Constants.OBJECTCLASS, a.getClassName()));
  String filter;
  if(conditions.size() > 1) {
    filter = combine(conditions);
  } else if(conditions.size() == 1) {
    filter = conditions.get(0);
  } else {
    filter = null;
  }
  return filter;
}
origin: org.jflux/org.jflux.swing.services

public void updateDisplay(Boolean status){
  updateStatus(status, null);
  if(myDependency == null){
    lblName.setText("--");
    lblFilter.setText("--");
    lblType.setText("--");
    return;
  }
  String name = myDependency.getDependencyName();
  Descriptor desc = myDependency.getDescriptor();
  String type = desc.getClassName();
  Properties props = new Properties();
  
  for(String key: desc.getPropertyKeys()){
    props.put(key, desc.getProperty(key));
  }
  
  String filter = OSGiUtils.createServiceFilter(props);
  
  name = name == null ? "--" : name;
  type = type == null ? "--" : type;
  filter = filter == null ? "--" : filter;
  lblName.setText(name);
  lblFilter.setText(filter);
  lblType.setText(type);
}

origin: org.rwshop/org.rwshop.swing.common

public void updateDisplay(Boolean status){
  updateStatus(status);
  if(myDependency == null){
    lblName.setText("--");
    lblFilter.setText("--");
    lblType.setText("--");
    return;
  }
  String name = myDependency.getDependencyName();
  Descriptor desc = myDependency.getDescriptor();
  String type = desc.getClassName();
  Properties props = new Properties();
  
  for(String key: desc.getPropertyKeys()){
    props.put(key, desc.getProperty(key));
  }
  
  String filter = OSGiUtils.createServiceFilter(props);
  
  name = name == null ? "--" : name;
  type = type == null ? "--" : type;
  filter = filter == null ? "--" : filter;
  lblName.setText(name);
  lblFilter.setText(filter);
  lblType.setText(type);
}

origin: org.jflux/org.jflux.swing.services

for(String key : desc.getPropertyKeys()){
  for(String f : myFilters){
    String s = desc.getProperty(key);
    Pattern p = Pattern.compile(
        ".*" + f + ".*",
  Descriptor desc = sb.getDescriptor();
  for(String key: desc.getPropertyKeys()){
    props.put(key, desc.getProperty(key));
origin: org.rwshop/org.rwshop.swing.common

for(String key : desc.getPropertyKeys()){
  for(String f : myFilters){
    String s = desc.getProperty(key);
    Pattern p = Pattern.compile(
        ".*" + f + ".*",
  Descriptor desc = sb.getDescriptor();
  for(String key: desc.getPropertyKeys()){
    props.put(key, desc.getProperty(key));
org.jflux.api.registryDescriptorgetProperty

Javadoc

Gets one of the descriptor's properties by name

Popular methods of Descriptor

  • getClassName
    Gets the name of the class associated with the descriptor
  • getPropertyKeys
    Gets all of the descriptor's properties

Popular in Java

  • Creating JSON documents from java classes using gson
  • getApplicationContext (Context)
  • setRequestProperty (URLConnection)
  • putExtra (Intent)
  • Component (java.awt)
    A component is an object having a graphical representation that can be displayed on the screen and t
  • Socket (java.net)
    Provides a client-side TCP socket.
  • SQLException (java.sql)
    An exception that indicates a failed JDBC operation. It provides the following information about pro
  • NoSuchElementException (java.util)
    Thrown when trying to retrieve an element past the end of an Enumeration or Iterator.
  • Scanner (java.util)
    A parser that parses a text string of primitive types and strings with the help of regular expressio
  • SSLHandshakeException (javax.net.ssl)
    The exception that is thrown when a handshake could not be completed successfully.
  • Top 17 PhpStorm Plugins
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

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