org.jbundle.model.db.Field.getData()方法的使用及代码示例

x33g5p2x  于2022-01-19 转载在 其他  
字(12.7k)|赞(0)|评价(0)|浏览(62)

本文整理了Java中org.jbundle.model.db.Field.getData()方法的一些代码示例,展示了Field.getData()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Field.getData()方法的具体详情如下:
包路径:org.jbundle.model.db.Field
类名称:Field
方法名:getData

Field.getData介绍

暂无

代码示例

代码示例来源:origin: org.jbundle.thin.base.db/org.jbundle.thin.base.db

/**
 * Compare field to this and return < > or = (-,+,0).
 * @return compare value.
 */
public int compareTo(Field field)
{ // Override this
  return this.compareTo(field.getData());
}
/**

代码示例来源:origin: org.jbundle.base/org.jbundle.base.mixed

/**
 * Compare field to this and return < > or = (-,+,0).
 * @return compare value.
 */
public int compareTo(Field field)
{
  if (field instanceof BaseField) if (!this.isSameType((BaseField)field))
    return super.compareTo(field);
  m_calendar.set(DBConstants.FIRST_YEAR, Calendar.JANUARY, 1, 0, 0, 0);
  java.util.Date dateSmall = m_calendar.getTime();
  java.util.Date time1 = dateSmall;
  java.util.Date time2 = dateSmall;
  java.util.Date dateValue = (java.util.Date)this.getData();  // Get the physical data
  if (dateValue != null)
    time1 = dateValue;
  dateValue = (java.util.Date)field.getData();    // Get the physical data
  if (dateValue != null)
    time2 = dateValue;
  return time1.compareTo(time2);
}
/**

代码示例来源:origin: org.jbundle.base/org.jbundle.base

/**
 * Compare field to this and return < > or = (-,+,0).
 * @return compare value.
 */
public int compareTo(Field field)
{
  if (field instanceof BaseField) if (!this.isSameType((BaseField)field))
    return super.compareTo(field);
  m_calendar.set(DBConstants.FIRST_YEAR, Calendar.JANUARY, 1, 0, 0, 0);
  java.util.Date dateSmall = m_calendar.getTime();
  java.util.Date time1 = dateSmall;
  java.util.Date time2 = dateSmall;
  java.util.Date dateValue = (java.util.Date)this.getData();  // Get the physical data
  if (dateValue != null)
    time1 = dateValue;
  dateValue = (java.util.Date)field.getData();    // Get the physical data
  if (dateValue != null)
    time2 = dateValue;
  return time1.compareTo(time2);
}
/**

代码示例来源:origin: org.jbundle.base/org.jbundle.base.mixed

/**
 * Compare field to this and return < > or = (-,+,0).
 */
public int compareTo(Field field)
{
  if (field instanceof BaseField) if (!this.isSameType((BaseField)field))
    return super.compareTo(field);
  double double1 = Double.MIN_VALUE, double2 = Double.MIN_VALUE;
  Double doubleField = (Double)this.getData();    // Get the physical data
  if (doubleField != null)
    double1 = doubleField.doubleValue();
  doubleField = (Double)field.getData();  // Get the physical data
  if (doubleField != null)
    double2 = doubleField.doubleValue();
  if (double1 == double2)
    return 0;
  if (double1 < double2)
    return -1;
  else
    return 1;
}
/**

代码示例来源:origin: org.jbundle.base/org.jbundle.base

/**
 * Compare field to this and return < > or = (-,+,0).
 * @return The compare value.
 */
public int compareTo(Field field)
{
  if (field instanceof BaseField) if (!this.isSameType((BaseField)field))
    return super.compareTo(field);
  int long1 = Integer.MIN_VALUE, long2 = Integer.MIN_VALUE;
  Integer tempLong = (Integer)this.getData();   // Get the physical data
  if (tempLong != null)
    long1 = tempLong.intValue();
  tempLong = (Integer)field.getData();    // Get the physical data
  if (tempLong != null)
    long2 = tempLong.intValue();
  if (long1 == long2)
    return 0;
  if (long1 < long2)
    return -1;
  else
    return 1;
}
/**

代码示例来源:origin: org.jbundle.base.db/org.jbundle.base.db

/**
 * Compare field to this and return < > or = (-,+,0).
 * @return compare value.
 */
public int compareTo(Field field)
{
  if (field instanceof BaseField) if (!this.isSameType((BaseField)field))
    return super.compareTo(field);
  m_calendar.set(DBConstants.FIRST_YEAR, Calendar.JANUARY, 1, 0, 0, 0);
  java.util.Date dateSmall = m_calendar.getTime();
  java.util.Date time1 = dateSmall;
  java.util.Date time2 = dateSmall;
  java.util.Date dateValue = (java.util.Date)this.getData();  // Get the physical data
  if (dateValue != null)
    time1 = dateValue;
  dateValue = (java.util.Date)field.getData();    // Get the physical data
  if (dateValue != null)
    time2 = dateValue;
  return time1.compareTo(time2);
}
/**

代码示例来源:origin: org.jbundle.thin.base.db/org.jbundle.thin.base.db

/**
 * Called each time a field changed.
 * This method replaces behaviors in the thick model. Just override this method and look for the
 * target field and do the listener associated with a change of value.
 * Note: The thin version (this one) keeps a flag for changes, the thick version surveys the fields.
 * @param field The field that changed.
 * @param iChangeType The type of change (See record for the list).
 * @param iDisplayOtion The display option.
 * @return The error code.
 */
public int doRecordChange(Field field, int iChangeType, boolean bDisplayOption)
{
  if (field != null)
    if (iChangeType == Constants.SCREEN_MOVE)
      this.firePropertyChange(field.getFieldName(), null, field.getData());
  return Constants.NORMAL_RETURN;
}
/**

代码示例来源:origin: org.jbundle.base.db/org.jbundle.base.db

/**
 * Compare field to this and return < > or = (-,+,0).
 */
public int compareTo(Field field)
{
  if (field instanceof BaseField) if (!this.isSameType((BaseField)field))
    return super.compareTo(field);
  double double1 = Double.MIN_VALUE, double2 = Double.MIN_VALUE;
  Double doubleField = (Double)this.getData();    // Get the physical data
  if (doubleField != null)
    double1 = doubleField.doubleValue();
  doubleField = (Double)field.getData();  // Get the physical data
  if (doubleField != null)
    double2 = doubleField.doubleValue();
  if (double1 == double2)
    return 0;
  if (double1 < double2)
    return -1;
  else
    return 1;
}
/**

代码示例来源:origin: org.jbundle.base/org.jbundle.base

/**
 * Compare field to this and return < > or = (-,+,0).
 */
public int compareTo(Field field)
{
  if (field instanceof BaseField) if (!this.isSameType((BaseField)field))
    return super.compareTo(field);
  double double1 = Double.MIN_VALUE, double2 = Double.MIN_VALUE;
  Double doubleField = (Double)this.getData();    // Get the physical data
  if (doubleField != null)
    double1 = doubleField.doubleValue();
  doubleField = (Double)field.getData();  // Get the physical data
  if (doubleField != null)
    double2 = doubleField.doubleValue();
  if (double1 == double2)
    return 0;
  if (double1 < double2)
    return -1;
  else
    return 1;
}
/**

代码示例来源:origin: org.jbundle.base/org.jbundle.base

/**
 * Compare field to this and return < > or = (-,+,0).
 * @return The compare value.
 */
public int compareTo(Field field)
{
  if (field instanceof BaseField) if (!this.isSameType((BaseField)field))
    return super.compareTo(field);
  short short1 = Short.MIN_VALUE, short2 = Short.MAX_VALUE;
  Short tempShort = (Short)this.getData();    // Get the physical data
  if (tempShort != null)
    short1 = tempShort.shortValue();
  tempShort = (Short)field.getData();   // Get the physical data
  if (tempShort != null)
    short2 = tempShort.shortValue();
  if (short1 == short2)
    return 0;
  if (short1 < short2)
    return -1;
  else
    return 1;
}
/**

代码示例来源:origin: org.jbundle.base/org.jbundle.base.mixed

/**
 * Compare field to this and return < > or = (-,+,0).
 * @return The compare value.
 */
public int compareTo(Field field)
{
  if (field instanceof BaseField) if (!this.isSameType((BaseField)field))
    return super.compareTo(field);
  short short1 = Short.MIN_VALUE, short2 = Short.MAX_VALUE;
  Short tempShort = (Short)this.getData();    // Get the physical data
  if (tempShort != null)
    short1 = tempShort.shortValue();
  tempShort = (Short)field.getData();   // Get the physical data
  if (tempShort != null)
    short2 = tempShort.shortValue();
  if (short1 == short2)
    return 0;
  if (short1 < short2)
    return -1;
  else
    return 1;
}
/**

代码示例来源:origin: org.jbundle.base/org.jbundle.base.mixed

/**
 * Compare field to this and return < > or = (-,+,0).
 * @return The compare value.
 */
public int compareTo(Field field)
{
  if (field instanceof BaseField) if (!this.isSameType((BaseField)field))
    return super.compareTo(field);
  float float1 = Float.MIN_VALUE, float2 = Float.MIN_VALUE;
  Float floatField = (Float)this.getData(); // Get the physical data
  if (floatField != null)
    float1 = floatField.floatValue();
  floatField = (Float)field.getData();    // Get the physical data
  if (floatField != null)
    float2 = floatField.floatValue();
  if (float1 == float2)
    return 0;
  if (float1 < float2)
    return -1;
  else
    return 1;
}
/**

代码示例来源:origin: org.jbundle.base/org.jbundle.base

/**
 * Compare field to this and return < > or = (-,+,0).
 * @return The compare value.
 */
public int compareTo(Field field)
{
  if (field instanceof BaseField) if (!this.isSameType((BaseField)field))
    return super.compareTo(field);
  float float1 = Float.MIN_VALUE, float2 = Float.MIN_VALUE;
  Float floatField = (Float)this.getData(); // Get the physical data
  if (floatField != null)
    float1 = floatField.floatValue();
  floatField = (Float)field.getData();    // Get the physical data
  if (floatField != null)
    float2 = floatField.floatValue();
  if (float1 == float2)
    return 0;
  if (float1 < float2)
    return -1;
  else
    return 1;
}
/**

代码示例来源:origin: org.jbundle.base.db/org.jbundle.base.db

/**
 * Compare field to this and return < > or = (-,+,0).
 * @return The compare value.
 */
public int compareTo(Field field)
{
  if (field instanceof BaseField) if (!this.isSameType((BaseField)field))
    return super.compareTo(field);
  short short1 = Short.MIN_VALUE, short2 = Short.MAX_VALUE;
  Short tempShort = (Short)this.getData();    // Get the physical data
  if (tempShort != null)
    short1 = tempShort.shortValue();
  tempShort = (Short)field.getData();   // Get the physical data
  if (tempShort != null)
    short2 = tempShort.shortValue();
  if (short1 == short2)
    return 0;
  if (short1 < short2)
    return -1;
  else
    return 1;
}
/**

代码示例来源:origin: org.jbundle.base/org.jbundle.base.mixed

/**
 * Compare field to this and return < > or = (-,+,0).
 * @return The compare value.
 */
public int compareTo(Field field)
{
  if (field instanceof BaseField) if (!this.isSameType((BaseField)field))
    return super.compareTo(field);
  int long1 = Integer.MIN_VALUE, long2 = Integer.MIN_VALUE;
  Integer tempLong = (Integer)this.getData();   // Get the physical data
  if (tempLong != null)
    long1 = tempLong.intValue();
  tempLong = (Integer)field.getData();    // Get the physical data
  if (tempLong != null)
    long2 = tempLong.intValue();
  if (long1 == long2)
    return 0;
  if (long1 < long2)
    return -1;
  else
    return 1;
}
/**

代码示例来源:origin: org.jbundle.base.db/org.jbundle.base.db

/**
 * Compare field to this and return < > or = (-,+,0).
 * @return The compare value.
 */
public int compareTo(Field field)
{
  if (field instanceof BaseField) if (!this.isSameType((BaseField)field))
    return super.compareTo(field);
  float float1 = Float.MIN_VALUE, float2 = Float.MIN_VALUE;
  Float floatField = (Float)this.getData(); // Get the physical data
  if (floatField != null)
    float1 = floatField.floatValue();
  floatField = (Float)field.getData();    // Get the physical data
  if (floatField != null)
    float2 = floatField.floatValue();
  if (float1 == float2)
    return 0;
  if (float1 < float2)
    return -1;
  else
    return 1;
}
/**

代码示例来源:origin: org.jbundle.base.db/org.jbundle.base.db

/**
 * Compare field to this and return < > or = (-,+,0).
 * @return The compare value.
 */
public int compareTo(Field field)
{
  if (field instanceof BaseField) if (!this.isSameType((BaseField)field))
    return super.compareTo(field);
  int long1 = Integer.MIN_VALUE, long2 = Integer.MIN_VALUE;
  Integer tempLong = (Integer)this.getData();   // Get the physical data
  if (tempLong != null)
    long1 = tempLong.intValue();
  tempLong = (Integer)field.getData();    // Get the physical data
  if (tempLong != null)
    long2 = tempLong.intValue();
  if (long1 == long2)
    return 0;
  if (long1 < long2)
    return -1;
  else
    return 1;
}
/**

代码示例来源:origin: com.tourgeek.tour/com.tourgeek.tour.product.db

objDetailDate = calendar.getTime();
if (objProductID != null)
  if (objProductID.equals(recTour.getField(TourModel.TOUR_HEADER_ID).getData()))
    if (objDetailDate != null)
      if (objDetailDate.equals(recTour.getField(TourModel.DEPARTURE_DATE).getData()))

代码示例来源:origin: com.tourgeek.tour/com.tourgeek.tour.product.db

public void done()
  { // 'Please wait...' is done displaying
    String strCommand = "addTourDetail";
    Map<String,Object> properties = new HashMap<String,Object>();
    properties.put(TourHeader.TOUR_HEADER_FILE, m_recTourHeader.getCounterField().getData());
    properties.put(m_recTour.getField(TourModel.DEPARTURE_DATE).getFieldName(), m_recTour.getField(TourModel.DEPARTURE_DATE).getData());
    Object objReturn;
    try {
      objReturn = ((Record)m_recBooking).handleRemoteCommand(strCommand, properties);
    } catch (RemoteException e) {
      e.printStackTrace();
      objReturn = Boolean.FALSE;
    } catch (DBException e) {
      e.printStackTrace();
      objReturn = Boolean.FALSE;
    }
    
    if (Boolean.FALSE.equals(objReturn))
    {                           
      BookingAnswerModel recBookingAnswer = null;  // This causes addTourDetail to resolve the answers automatically
      BookingPaxModel recBookingPax = null;
      Date dateStart = ((DateTimeField)m_recTour.getField(TourModel.DEPARTURE_DATE)).getDateTime();  // Use tour departure date.
      ((BookingModel)m_recBooking).addTourDetail(m_recTour, m_recTourHeader, recBookingPax, recBookingAnswer, dateStart, m_recBooking.getField(BookingModel.ASK_FOR_ANSWER));
    }
  }
};

代码示例来源:origin: com.tourapp.tour/com.tourapp.tour.product.db

public void done()
  { // 'Please wait...' is done displaying
    String strCommand = "addTourDetail";
    Map<String,Object> properties = new HashMap<String,Object>();
    properties.put(TourHeader.TOUR_HEADER_FILE, m_recTourHeader.getCounterField().getData());
    properties.put(m_recTour.getField(TourModel.DEPARTURE_DATE).getFieldName(), m_recTour.getField(TourModel.DEPARTURE_DATE).getData());
    Object objReturn;
    try {
      objReturn = ((Record)m_recBooking).handleRemoteCommand(strCommand, properties);
    } catch (RemoteException e) {
      e.printStackTrace();
      objReturn = Boolean.FALSE;
    } catch (DBException e) {
      e.printStackTrace();
      objReturn = Boolean.FALSE;
    }
    
    if (Boolean.FALSE.equals(objReturn))
    {                           
      BookingAnswerModel recBookingAnswer = null;  // This causes addTourDetail to resolve the answers automatically
      BookingPaxModel recBookingPax = null;
      Date dateStart = ((DateTimeField)m_recTour.getField(TourModel.DEPARTURE_DATE)).getDateTime();  // Use tour departure date.
      ((BookingModel)m_recBooking).addTourDetail(m_recTour, m_recTourHeader, recBookingPax, recBookingAnswer, dateStart, m_recBooking.getField(BookingModel.ASK_FOR_ANSWER));
    }
  }
};

相关文章