congrats Icon
New! Tabnine Pro 14-day free trial
Start a free trial
Tabnine Logo
Property.getKey
Code IndexAdd Tabnine to your IDE (free)

How to use
getKey
method
in
org.gradoop.common.model.impl.properties.Property

Best Java code snippets using org.gradoop.common.model.impl.properties.Property.getKey (Showing top 20 results out of 315)

origin: dbs-leipzig/gradoop

@Override
public int compareTo(Property o) {
 return this.getKey().compareTo(o.getKey());
}
origin: dbs-leipzig/gradoop

/**
 * Removes the given property from the list.
 *
 * @param property property
 * @return the previous value associated with <tt>key</tt>, or
 *         <tt>null</tt> if there was no mapping for <tt>key</tt>.
 */
public PropertyValue remove(Property property) {
 Objects.requireNonNull(property);
 return remove(property.getKey());
}
origin: org.gradoop/gradoop-flink

/**
 * Valued constructor, accepts all elements containing the given property.
 *
 * @param property property, containing of key and value
 */
public ByProperty(Property property) {
 this(property.getKey(), property.getValue());
}
origin: dbs-leipzig/gradoop

/**
 * Valued constructor, accepts all elements containing the given property.
 *
 * @param property property, containing of key and value
 */
public ByProperty(Property property) {
 this(property.getKey(), property.getValue());
}
origin: org.gradoop/gradoop-flink

/**
 * Returns the property meta data string for the specified property. The string consists of the
 * property key and the property value type, e.g. "foo:int".
 *
 * @param property property
 * @return property meta data
 */
public static String getPropertyMetaData(Property property) {
 return String.format("%s%s%s",
  property.getKey(), PROPERTY_TOKEN_DELIMITER, getTypeString(property.getValue()));
}
origin: dbs-leipzig/gradoop

/**
 * Returns the property meta data string for the specified property. The string consists of the
 * property key and the property value type, e.g. "foo:int".
 *
 * @param property property
 * @return property meta data
 */
public static String getPropertyMetaData(Property property) {
 return String.format("%s%s%s",
  property.getKey(), PROPERTY_TOKEN_DELIMITER, getTypeString(property.getValue()));
}
origin: dbs-leipzig/gradoop

/**
 * Sets the given property. If a property with the same property key already
 * exists, it will be replaced by the given property.
 *
 * @param property property
 */
public void set(Property property) {
 set(property.getKey(), property.getValue());
}
origin: dbs-leipzig/gradoop

/**
 * Returns the property meta data string for the specified property. The string consists of the
 * property key and the property value type, e.g. "foo:int".
 *
 * @param property property
 * @return property meta data
 */
public static String getPropertyMetaData(Property property) {
 return String.format("%s%s%s",
  StringEscaper.escape(property.getKey(), CSVConstants.ESCAPED_CHARACTERS),
  MetaData.PROPERTY_TOKEN_DELIMITER,
  MetaData.getTypeString(property.getValue())); // no need to escape
}
origin: dbs-leipzig/gradoop

@Override
public Put writeProperty(final Put put, Property property) {
 byte[] type = PropertyValueUtils.Bytes.getTypeByte(property.getValue());
 byte[] bytesWithoutType = PropertyValueUtils.Bytes.getRawBytesWithoutType(property.getValue());
 put.addColumn(CF_PROPERTY_TYPE_BYTES, Bytes.toBytes(property.getKey()), type);
 put.addColumn(CF_PROPERTY_VALUE_BYTES, Bytes.toBytes(property.getKey()), bytesWithoutType);
 return put;
}
origin: org.gradoop/gradoop-flink

/**
 * Returns the property meta data string for the specified property. The string consists of the
 * property key and the property value type, e.g. "foo:int".
 *
 * @param property property
 * @return property meta data
 */
public static String getPropertyMetaData(Property property) {
 return String.format("%s%s%s",
  StringEscaper.escape(property.getKey(), CSVConstants.ESCAPED_CHARACTERS),
  MetaData.PROPERTY_TOKEN_DELIMITER,
  MetaData.getTypeString(property.getValue())); // no need to escape
}
origin: dbs-leipzig/gradoop

 @Override
 public void flatMap(T value, Collector<Tuple2<String, Set<PropertyValue>>> out) throws Exception {
  if (value.getProperties() != null) {
   for (Property property : value.getProperties()) {
    reuseTuple.f0 = property.getKey();
    reuseTuple.f1 = Sets.newHashSet(property.getValue());

    out.collect(reuseTuple);
   }
  }
 }
}
origin: org.gradoop/gradoop-flink

 @Override
 public void flatMap(T value, Collector<Tuple2<String, Set<PropertyValue>>> out) throws Exception {
  if (value.getProperties() != null) {
   for (Property property : value.getProperties()) {
    reuseTuple.f0 = property.getKey();
    reuseTuple.f1 = Sets.newHashSet(property.getValue());

    out.collect(reuseTuple);
   }
  }
 }
}
origin: org.gradoop/gradoop-flink

Property property = iterator.next();
builder.append("<tr><td>")
 .append(escapeHtml4(property.getKey()))
 .append("</td><td>")
 .append(escapeHtml4(property.getValue().toString()))
origin: org.gradoop/gradoop-flink

 /**
  * Returns this property as a GDL formatted String.
  *
  * @param property The property.
  * @return A GDL formatted string that represents the property.
  */
 private String propertyToGDLString(Property property) {
  StringBuilder result = new StringBuilder()
   .append(property.getKey())
   .append(KEY_VALUE_SEPARATOR);

  PropertyValue value = property.getValue();

  if (value.isString()) {
   result.append(STRING_PREFIX).append(value.toString()).append(STRING_SUFFIX);
  } else if (value.isNull()) {
   result.append(NULL_STRING);
  } else if (value.isDouble()) {
   result.append(value.toString()).append(DOUBLE_SUFFIX);
  } else if (value.isFloat()) {
   result.append(value.toString()).append(FLOAT_SUFFIX);
  } else if (value.isLong()) {
   result.append(value.toString()).append(LONG_SUFFIX);
  } else {
   result.append(value.toString());
  }

  return result.toString();
 }
}
origin: dbs-leipzig/gradoop

 /**
  * Returns this property as a GDL formatted String.
  *
  * @param property The property.
  * @return A GDL formatted string that represents the property.
  */
 private String propertyToGDLString(Property property) {
  StringBuilder result = new StringBuilder()
   .append(property.getKey())
   .append(KEY_VALUE_SEPARATOR);

  PropertyValue value = property.getValue();

  if (value.isString()) {
   result.append(STRING_PREFIX).append(value.toString()).append(STRING_SUFFIX);
  } else if (value.isNull()) {
   result.append(NULL_STRING);
  } else if (value.isDouble()) {
   result.append(value.toString()).append(DOUBLE_SUFFIX);
  } else if (value.isFloat()) {
   result.append(value.toString()).append(FLOAT_SUFFIX);
  } else if (value.isLong()) {
   result.append(value.toString()).append(LONG_SUFFIX);
  } else {
   result.append(value.toString());
  }

  return result.toString();
 }
}
origin: org.gradoop/gradoop-flink

 @Override
 public void flatMap(T value, Collector<Tuple2<Tuple2<String, String>, Set<PropertyValue>>> out)
   throws Exception {

  if (value.getProperties() != null) {
   for (Property property : value.getProperties()) {
    reuseTuple.f0.f0 = value.getLabel();
    reuseTuple.f0.f1 = property.getKey();
    reuseTuple.f1 = Sets.newHashSet(property.getValue());

    out.collect(reuseTuple);
   }
  }
 }
}
origin: dbs-leipzig/gradoop

 @Override
 public void flatMap(T value, Collector<Tuple2<Tuple2<String, String>, Set<PropertyValue>>> out)
   throws Exception {

  if (value.getProperties() != null) {
   for (Property property : value.getProperties()) {
    reuseTuple.f0.f0 = value.getLabel();
    reuseTuple.f0.f1 = property.getKey();
    reuseTuple.f1 = Sets.newHashSet(property.getValue());

    out.collect(reuseTuple);
   }
  }
 }
}
origin: dbs-leipzig/gradoop

@Test
public void testIterator() throws Exception {
 Properties properties = Properties.createFromMap(SUPPORTED_PROPERTIES);
 for (Property property : properties) {
  assertTrue(SUPPORTED_PROPERTIES.containsKey(property.getKey()));
  assertEquals(SUPPORTED_PROPERTIES.get(property.getKey()),
   property.getValue().getObject());
 }
}
origin: dbs-leipzig/gradoop

@Test
public void testGetKey() throws Exception {
 Property property = new Property("key", PropertyValue.create(10));
 assertEquals("key", property.getKey());
}
origin: dbs-leipzig/gradoop

@Test
public void testSetKey() throws Exception {
 Property property = new Property("key", PropertyValue.create(10));
 property.setKey("newKey");
 assertEquals("newKey", property.getKey());
}
org.gradoop.common.model.impl.propertiesPropertygetKey

Javadoc

Returns the property key.

Popular methods of Property

  • getValue
  • create
    Creates a new property from the given arguments.
  • <init>
    Creates a new property from the given arguments.
  • compareTo
  • hashCode
  • setKey
    Sets the property key.
  • setValue
    Sets the property value.
  • toString

Popular in Java

  • Making http requests using okhttp
  • onRequestPermissionsResult (Fragment)
  • getOriginalFilename (MultipartFile)
    Return the original filename in the client's filesystem.This may contain path information depending
  • onCreateOptionsMenu (Activity)
  • Menu (java.awt)
  • Window (java.awt)
    A Window object is a top-level window with no borders and no menubar. The default layout for a windo
  • System (java.lang)
    Provides access to system-related information and resources including standard input and output. Ena
  • Path (java.nio.file)
  • Calendar (java.util)
    Calendar is an abstract base class for converting between a Date object and a set of integer fields
  • NoSuchElementException (java.util)
    Thrown when trying to retrieve an element past the end of an Enumeration or Iterator.
  • Top plugins for WebStorm
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