org.codehaus.jackson.annotate.JsonIgnore Java Examples

The following examples show how to use org.codehaus.jackson.annotate.JsonIgnore. You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: AtlasEntity.java    From incubator-atlas with Apache License 2.0 6 votes vote down vote up
@JsonIgnore
@Override
public AtlasEntity getEntity(String guid) {
    AtlasEntity ret = super.getEntity(guid);

    if (ret == null && CollectionUtils.isNotEmpty(entities)) {
        for (AtlasEntity entity : entities) {
            if (StringUtils.equals(guid, entity.getGuid())) {
                ret = entity;

                break;
            }
        }
    }

    return ret;
}
 
Example #2
Source File: CellStyle.java    From ureport with Apache License 2.0 6 votes vote down vote up
@JsonIgnore
public Font getFont(){
	if(this.font==null){
		int fontStyle=Font.PLAIN;
		if((bold!=null && bold) && (italic!=null && italic)){
			fontStyle=Font.BOLD|Font.ITALIC;				
		}else if(bold!=null && bold){
			fontStyle=Font.BOLD;							
		}else if(italic!=null && italic){
			fontStyle=Font.ITALIC;							
		}
		String fontName=fontFamily;
		if(StringUtils.isBlank(fontName)){
			fontName="宋体";
		}
		this.font=FontBuilder.getAwtFont(fontName, fontStyle, new Float(fontSize));
	}
	return this.font;
}
 
Example #3
Source File: TopologyTestRunCaseSource.java    From streamline with Apache License 2.0 5 votes vote down vote up
@JsonIgnore
@Override
public PrimaryKey getPrimaryKey() {
    Map<Schema.Field, Object> fieldToObjectMap = new HashMap<Schema.Field, Object>();
    fieldToObjectMap.put(new Schema.Field("id", Schema.Type.LONG), this.id);
    return new PrimaryKey(fieldToObjectMap);
}
 
Example #4
Source File: AtlasEntity.java    From incubator-atlas with Apache License 2.0 5 votes vote down vote up
@JsonIgnore
@Override
public AtlasEntity getEntity(String guid) {
    AtlasEntity ret = super.getEntity(guid);

    if (ret == null && entity != null) {
        if (StringUtils.equals(guid, entity.getGuid())) {
            ret = entity;
        }
    }

    return ret;
}
 
Example #5
Source File: DatastreamTaskImpl.java    From brooklin with BSD 2-Clause "Simplified" License 5 votes vote down vote up
@JsonIgnore
@Override
public DatastreamTaskStatus getStatus() {
  String statusStr = getState(STATUS);
  if (statusStr != null && !statusStr.isEmpty()) {
    return JsonUtils.fromJson(statusStr, DatastreamTaskStatus.class);
  }
  return null;
}
 
Example #6
Source File: AtlasEntity.java    From incubator-atlas with Apache License 2.0 5 votes vote down vote up
@JsonIgnore
public final void addReferredEntity(String guid, AtlasEntity entity) {
    Map<String, AtlasEntity> r = this.referredEntities;

    if (r == null) {
        r = new HashMap<>();

        this.referredEntities = r;
    }

    if (guid != null) {
        r.put(guid, entity);
    }
}
 
Example #7
Source File: Element.java    From query2report with GNU General Public License v3.0 5 votes vote down vote up
@JsonIgnore
public Set<String> getDimColNames() {
	Set<String> toReturn = new HashSet<String>();
	Set<String> dateTimeCols = this.dataTypeToColumnNames.get(DashboardConstants.DATETIME);
	if(dateTimeCols!=null)
		toReturn.addAll(dateTimeCols);

	Set<String> stringCols = this.dataTypeToColumnNames.get(DashboardConstants.STRING);
	if(stringCols!=null)
		toReturn.addAll(stringCols);

	return toReturn;
}
 
Example #8
Source File: AtlasEntity.java    From incubator-atlas with Apache License 2.0 5 votes vote down vote up
@JsonIgnore
@Override
public void compact() {
    super.compact();

    // remove 'entity' from referredEntities
    if (entity != null) {
        removeEntity(entity.getGuid());
    }
}
 
Example #9
Source File: Element.java    From query2report with GNU General Public License v3.0 5 votes vote down vote up
@JsonIgnore
public Set<String> getMetricColNames() {
	Set<String> toReturn = new HashSet<String>();
	Set<String> metricCols = this.dataTypeToColumnNames.get(DashboardConstants.NUMBER);
	if(metricCols!=null)
		toReturn.addAll(metricCols);
	return toReturn;

}
 
Example #10
Source File: EntityMutationResponse.java    From incubator-atlas with Apache License 2.0 5 votes vote down vote up
@JsonIgnore
public List<AtlasEntityHeader> getDeletedEntities() {
    if ( mutatedEntities != null) {
        return mutatedEntities.get(EntityOperation.DELETE);
    }
    return null;
}
 
Example #11
Source File: EntityMutationResponse.java    From incubator-atlas with Apache License 2.0 5 votes vote down vote up
@JsonIgnore
public List<AtlasEntityHeader> getUpdatedEntities() {
    if ( mutatedEntities != null) {
        return mutatedEntities.get(EntityOperation.UPDATE);
    }
    return null;
}
 
Example #12
Source File: StatePool.java    From hadoop with Apache License 2.0 5 votes vote down vote up
@JsonIgnore
public boolean isUpdated() {
  if (!isUpdated) {
    for (StatePair statePair : pool.values()) {
      // if one of the states have changed, then the pool is dirty
      if (statePair.getState().isUpdated()) {
        isUpdated = true;
        return true;
      }
    }
  }
  return isUpdated;
}
 
Example #13
Source File: User.java    From query2report with GNU General Public License v3.0 5 votes vote down vote up
@JsonIgnore
	public String generateToken(){
		SecureRandom randomGenerator = new SecureRandom();
		Integer randomNumber = randomGenerator.nextInt(10000);
		double currNanoTime = System.nanoTime();
		double durationNanoTime = ((double)this.sessionTimeout)*(1000000000);
		double expNanoTime = currNanoTime+durationNanoTime;
		String key = this.username+":"+randomNumber.toString()+":"+expNanoTime;
		byte[] dataBytes = key.getBytes(StandardCharsets.UTF_8);
		authToken = username+"_0_"+Base64.getEncoder().encodeToString(dataBytes)+"_0_"+role;
		System.out.println(authToken);
		logger.info("Token for user "+this.username+" is "+this.authToken);
//		authToken = username+"_0_"+key+"_0_"+role;
		return authToken;
	}
 
Example #14
Source File: EntityMutationResponse.java    From incubator-atlas with Apache License 2.0 5 votes vote down vote up
@JsonIgnore
public List<AtlasEntityHeader> getCreatedEntities() {
    if ( mutatedEntities != null) {
        return mutatedEntities.get(EntityOperation.CREATE);
    }
    return null;
}
 
Example #15
Source File: EntityMutationResponse.java    From incubator-atlas with Apache License 2.0 5 votes vote down vote up
@JsonIgnore
public AtlasEntityHeader getFirstEntityPartialUpdated() {
    final List<AtlasEntityHeader> entitiesByOperation = getEntitiesByOperation(EntityOperation.PARTIAL_UPDATE);
    if ( entitiesByOperation != null && entitiesByOperation.size() > 0) {
        return entitiesByOperation.get(0);
    }

    return null;
}
 
Example #16
Source File: EntityMutationResponse.java    From incubator-atlas with Apache License 2.0 5 votes vote down vote up
@JsonIgnore
public AtlasEntityHeader getFirstEntityCreated() {
    final List<AtlasEntityHeader> entitiesByOperation = getEntitiesByOperation(EntityOperation.CREATE);
    if ( entitiesByOperation != null && entitiesByOperation.size() > 0) {
        return entitiesByOperation.get(0);
    }

    return null;
}
 
Example #17
Source File: AtlasMetrics.java    From incubator-atlas with Apache License 2.0 5 votes vote down vote up
@JsonIgnore
public Number getMetric(String groupKey, String key) {
    Map<String, Map<String, Number>> data = this.data;
    if (data == null) {
        return null;
    } else {
        Map<String, Number> metricMap = data.get(groupKey);
        if (metricMap == null || metricMap.isEmpty()) {
            return null;
        } else {
            return metricMap.get(key);
        }
    }
}
 
Example #18
Source File: AtlasMetrics.java    From incubator-atlas with Apache License 2.0 5 votes vote down vote up
@JsonIgnore
public void addData(String groupKey, String key, Number value) {
    Map<String, Map<String, Number>> data = this.data;
    if (data == null) {
        data = new HashMap<>();
    }
    Map<String, Number> metricMap = data.get(groupKey);
    if (metricMap == null) {
        metricMap = new HashMap<>();
        data.put(groupKey, metricMap);
    }
    metricMap.put(key, value);
    setData(data);
}
 
Example #19
Source File: JdbcStore.java    From attic-apex-malhar with Apache License 2.0 5 votes vote down vote up
@Override
@JsonIgnore
public boolean isConnected()
{
  try {
    return connection != null ? !connection.isClosed() : false;
  } catch (SQLException e) {
    throw new RuntimeException("is isConnected", e);
  }
}
 
Example #20
Source File: CgFormFieldEntity.java    From jeewx with Apache License 2.0 5 votes vote down vote up
/**
 *方法: 取得TablePropertyEntity
 *@return: TablePropertyEntity  关联的表ID
 */
@ManyToOne
@JoinColumn(name ="table_id",nullable=false,referencedColumnName="id")
@JsonIgnore
@ForeignKey(name="null")
public CgFormHeadEntity getTable(){
	return this.table;
}
 
Example #21
Source File: ZookeeperConnection.java    From nakadi with MIT License 5 votes vote down vote up
@JsonIgnore
public String getPathPrepared() {
    if (null == path) {
        return "";
    } else {
        return path.startsWith("/") ? path : ("/" + path);
    }
}
 
Example #22
Source File: AtlasTypesDef.java    From incubator-atlas with Apache License 2.0 5 votes vote down vote up
@JsonIgnore
public boolean isEmpty() {
    return CollectionUtils.isEmpty(enumDefs) &&
            CollectionUtils.isEmpty(structDefs) &&
            CollectionUtils.isEmpty(classificationDefs) &&
            CollectionUtils.isEmpty(entityDefs) &&
            CollectionUtils.isEmpty(relationshipDefs);
}
 
Example #23
Source File: TestImpl.java    From Asqatasun with GNU Affero General Public License v3.0 5 votes vote down vote up
/**
 *
 * @return @deprecated
 */
@Deprecated
@Override
@JsonIgnore
public String getFullCode() {
    if (criterion == null) {
        return "";
    }

    Reference reference = this.criterion.getReference();
    Theme theme = this.criterion.getTheme();

    return reference.getCode() + theme.getCode() + criterion.getCode()
            + this.getCode();
}
 
Example #24
Source File: EvidenceImpl.java    From Asqatasun with GNU Affero General Public License v3.0 5 votes vote down vote up
@Override
@JsonIgnore
public Collection<String> getValueList() {
    Collection<String> values = new HashSet<>();
    for (EvidenceElement element : elementList) {
        values.add(element.getValue());
    }
    return values;
}
 
Example #25
Source File: StatePool.java    From big-c with Apache License 2.0 5 votes vote down vote up
@JsonIgnore
public boolean isUpdated() {
  if (!isUpdated) {
    for (StatePair statePair : pool.values()) {
      // if one of the states have changed, then the pool is dirty
      if (statePair.getState().isUpdated()) {
        isUpdated = true;
        return true;
      }
    }
  }
  return isUpdated;
}
 
Example #26
Source File: JPAEntity.java    From spring-mvc-angular-js-hibernate-bootstrap-java-single-page-jwt-auth-rest-api-webapp-framework with MIT License 4 votes vote down vote up
@JsonIgnore @Temporal(TemporalType.DATE) @Column
public Date getCreatedAt() {
    return createdAt;
}
 
Example #27
Source File: Qualifier.java    From Eagle with Apache License 2.0 4 votes vote down vote up
@JsonIgnore
public EntitySerDeser<Object> getSerDeser() {
	return serDeser;
}
 
Example #28
Source File: DatastreamTaskImpl.java    From brooklin with BSD 2-Clause "Simplified" License 4 votes vote down vote up
/**
 * check if task has acquired lock
 */
@JsonIgnore
public boolean isLocked() {
  Validate.notNull(_zkAdapter, "Task is not properly initialized for processing.");
  return _zkAdapter.checkIsTaskLocked(_connectorType, getDatastreamTaskName());
}
 
Example #29
Source File: EntityMutationResponse.java    From incubator-atlas with Apache License 2.0 4 votes vote down vote up
@JsonIgnore

    public AtlasEntityHeader getUpdatedEntityByTypeNameAndAttribute(String typeName, String attrName, String attrVal) {
        return getEntityByTypeAndUniqueAttribute(getEntitiesByOperation(EntityOperation.UPDATE), typeName, attrName, attrVal);
    }
 
Example #30
Source File: TSBaseUser.java    From jeewx with Apache License 2.0 4 votes vote down vote up
@JsonIgnore    //getList查询转换为列表时处理json转换异常
@ManyToOne(fetch = FetchType.LAZY)
@JoinColumn(name = "departid")
public TSDepart getTSDepart() {
	return this.TSDepart;
}