Search in sources :

Example 61 with JsonIgnore

use of org.apache.flink.shaded.jackson2.com.fasterxml.jackson.annotation.JsonIgnore in project streamline by hortonworks.

the class TopologyEdge method setStreamGroupingsData.

@JsonIgnore
public void setStreamGroupingsData(String streamGroupingData) throws Exception {
    if (!StringUtils.isEmpty(streamGroupingData)) {
        ObjectMapper mapper = new ObjectMapper();
        streamGroupings = mapper.readValue(streamGroupingData, new TypeReference<List<StreamGrouping>>() {
        });
    }
}
Also used : TypeReference(com.fasterxml.jackson.core.type.TypeReference) ObjectMapper(com.fasterxml.jackson.databind.ObjectMapper) JsonIgnore(com.fasterxml.jackson.annotation.JsonIgnore)

Example 62 with JsonIgnore

use of org.apache.flink.shaded.jackson2.com.fasterxml.jackson.annotation.JsonIgnore in project streamline by hortonworks.

the class TopologyStream method getPrimaryKey.

@JsonIgnore
@Override
public PrimaryKey getPrimaryKey() {
    Map<Field, Object> fieldToObjectMap = new HashMap<>();
    fieldToObjectMap.put(new Schema.Field(ID, Schema.Type.LONG), this.id);
    fieldToObjectMap.put(new Schema.Field(VERSIONID, Schema.Type.LONG), this.versionId);
    return new PrimaryKey(fieldToObjectMap);
}
Also used : Field(com.hortonworks.registries.common.Schema.Field) HashMap(java.util.HashMap) Schema(com.hortonworks.registries.common.Schema) PrimaryKey(com.hortonworks.registries.storage.PrimaryKey) Field(com.hortonworks.registries.common.Schema.Field) JsonIgnore(com.fasterxml.jackson.annotation.JsonIgnore)

Example 63 with JsonIgnore

use of org.apache.flink.shaded.jackson2.com.fasterxml.jackson.annotation.JsonIgnore in project registry by hortonworks.

the class MLModel method getPrimaryKey.

@JsonIgnore
@Override
public PrimaryKey getPrimaryKey() {
    Map<Field, Object> fieldObjectMap = new HashMap<>();
    fieldObjectMap.put(new Schema.Field(ID, Type.LONG), this.id);
    return new PrimaryKey(fieldObjectMap);
}
Also used : Field(com.hortonworks.registries.common.Schema.Field) HashMap(java.util.HashMap) Schema(com.hortonworks.registries.common.Schema) PrimaryKey(com.hortonworks.registries.storage.PrimaryKey) Field(com.hortonworks.registries.common.Schema.Field) JsonIgnore(com.fasterxml.jackson.annotation.JsonIgnore)

Example 64 with JsonIgnore

use of org.apache.flink.shaded.jackson2.com.fasterxml.jackson.annotation.JsonIgnore in project ma-modules-public by infiniteautomation.

the class UserCommentModel method getDataAsComment.

/**
 * @return
 */
@JsonIgnore
public UserCommentVO getDataAsComment() {
    UserCommentVO comment = new UserCommentVO();
    comment.setId(this.data.getId());
    comment.setXid(this.data.getXid());
    comment.setUserId(this.data.getUserId());
    comment.setUsername(this.data.getUsername());
    comment.setTs(this.data.getTs());
    comment.setComment(this.data.getComment());
    return comment;
}
Also used : UserCommentVO(com.serotonin.m2m2.vo.comment.UserCommentVO) JsonIgnore(com.fasterxml.jackson.annotation.JsonIgnore)

Example 65 with JsonIgnore

use of org.apache.flink.shaded.jackson2.com.fasterxml.jackson.annotation.JsonIgnore in project halyard by spinnaker.

the class SpinnakerRuntimeSettings method getAllServiceSettings.

@JsonIgnore
public Map<SpinnakerService.Type, ServiceSettings> getAllServiceSettings() {
    return Arrays.stream(Services.class.getDeclaredFields()).reduce(new HashMap<>(), (map, field) -> {
        if (!ServiceSettings.class.isAssignableFrom(field.getType())) {
            return map;
        }
        SpinnakerService.Type type = SpinnakerService.Type.fromCanonicalName(field.getName());
        ServiceSettings settings;
        try {
            settings = (ServiceSettings) field.get(services);
        } catch (IllegalAccessException e) {
            throw new RuntimeException(e);
        }
        if (settings != null) {
            map.put(type, settings);
        }
        return map;
    }, (map1, map2) -> {
        map1.putAll(map2);
        return map1;
    });
}
Also used : ServiceSettings(com.netflix.spinnaker.halyard.deploy.spinnaker.v1.service.ServiceSettings) SpinnakerService(com.netflix.spinnaker.halyard.deploy.spinnaker.v1.service.SpinnakerService) JsonIgnore(com.fasterxml.jackson.annotation.JsonIgnore)

Aggregations

JsonIgnore (com.fasterxml.jackson.annotation.JsonIgnore)113 lombok.val (lombok.val)14 ArrayList (java.util.ArrayList)12 HashMap (java.util.HashMap)8 Map (java.util.Map)8 HashSet (java.util.HashSet)7 ObjectMapper (com.fasterxml.jackson.databind.ObjectMapper)5 Date (java.util.Date)5 Field (com.hortonworks.registries.common.Schema.Field)4 Set (java.util.Set)4 Schema (com.hortonworks.registries.common.Schema)3 PrimaryKey (com.hortonworks.registries.storage.PrimaryKey)3 EntitlementException (com.sun.identity.entitlement.EntitlementException)3 PolicyException (com.sun.identity.policy.PolicyException)3 JsonArray (io.vertx.core.json.JsonArray)3 List (java.util.List)3 SequenceFile (ca.corefacility.bioinformatics.irida.model.sequenceFile.SequenceFile)2 TrustAndKeyProvider (com.codingchili.core.security.TrustAndKeyProvider)2 JsonProcessingException (com.fasterxml.jackson.core.JsonProcessingException)2 TypeReference (com.fasterxml.jackson.core.type.TypeReference)2