From: Hyunjong.park Date: Tue, 4 Nov 2014 07:26:44 +0000 (+0900) Subject: thread : disable the state series of the parent sync chart, and change DB column... X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=4f5c4c1654e905ade5c2478d352b6e20df504608;p=sdk%2Ftools%2Fdynamic-analyzer.git thread : disable the state series of the parent sync chart, and change DB column name Signed-off-by: Hyunjong.park Change-Id: I6fa34a19a9d5a499ed006c04b2b2f6bf5a59d55b Signed-off-by: Hyunjong.park --- diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/thread/chart/SyncChart.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/thread/chart/SyncChart.java index 000c89d..a4a311c 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/thread/chart/SyncChart.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/thread/chart/SyncChart.java @@ -168,10 +168,12 @@ public class SyncChart { case LogCenterConstants.SYNC_API_TYPE_NOTIFY: case LogCenterConstants.SYNC_API_TYPE_NOTIFY_ALL: case LogCenterConstants.SYNC_API_TYPE_OTHER: - syncStateSeries.addSeriesItem(new DAChartSeriesItem(startTime, - DAChartSeriesItem.SERIES_STATE_BAR, - ColorResources.THREAD_GRAPH_LOCK_RELEASE_COLOR, - ThreadPageLabels.SYNC_CHART_ITEM_UNUSED)); + if (chartType == SYNC_CHILD_CHART) { + syncStateSeries.addSeriesItem(new DAChartSeriesItem(startTime, + DAChartSeriesItem.SERIES_STATE_BAR, + ColorResources.THREAD_GRAPH_LOCK_RELEASE_COLOR, + ThreadPageLabels.SYNC_CHART_ITEM_UNUSED)); + } syncAPISeries.addSeriesItem(createAPIItem(syncEvent, errorNum)); break; case LogCenterConstants.SYNC_API_TYPE_ACQUIRE_WAIT_START: diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/thread/chart/SyncChartBoard.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/thread/chart/SyncChartBoard.java index d691f34..c246fd4 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/thread/chart/SyncChartBoard.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/thread/chart/SyncChartBoard.java @@ -350,7 +350,7 @@ public class SyncChartBoard extends DAChartBoard { String tooltip = rs.getString(SyncEventDBTable.COLUMN.TOOLTIP.index + 1); long errorNum = rs.getLong(SyncEventDBTable.COLUMN.ERRORNO.index + 1); long syncValue = rs.getLong(SyncEventDBTable.COLUMN.SYNCVALUE.index + 1); - long releaseTime = rs.getLong(SyncEventDBTable.COLUMN.RELEASETIME.index + 1); + long releaseTime = rs.getLong(SyncEventDBTable.COLUMN.BLOCKENDTIME.index + 1); ThreadPageSyncDataEvent syncData = new ThreadPageSyncDataEvent(time, apiType, tooltip, errorNum, Long.toString(syncValue)); syncData.setSyncDataID(syncDataID); diff --git a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/thread/db/SyncEventDBTable.java b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/thread/db/SyncEventDBTable.java index a850109..fe863f9 100644 --- a/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/thread/db/SyncEventDBTable.java +++ b/org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/thread/db/SyncEventDBTable.java @@ -53,7 +53,7 @@ public class SyncEventDBTable extends DBTable { + CommonConstants.COMMA + COLUMN.APITYPE.name + CommonConstants.COMMA + COLUMN.TOOLTIP.name + CommonConstants.COMMA + COLUMN.ERRORNO.name + CommonConstants.COMMA + COLUMN.SYNCVALUE.name + CommonConstants.COMMA - + COLUMN.RELEASETIME.name; + + COLUMN.BLOCKENDTIME.name; public static final String SELECT_QUERY = "select " + SELECT_COLUMN + " from " + TABLENAME @@ -69,12 +69,12 @@ public class SyncEventDBTable extends DBTable { + COLUMN.APITYPE.name + " = " + LogCenterConstants.SYNC_API_TYPE_TRY_ACQUIRE + " OR " + COLUMN.APITYPE.name + " = " + LogCenterConstants.SYNC_API_TYPE_COND_WAIT_START + " OR " + COLUMN.APITYPE.name + " = " + LogCenterConstants.SYNC_API_TYPE_COND_WAIT_END + ") AND (" - + COLUMN.RELEASETIME.name + " >= %s AND " + COLUMN.EVENTTIME.name + " <= %s))"; + + COLUMN.BLOCKENDTIME.name + " >= %s AND " + COLUMN.EVENTTIME.name + " <= %s))"; public enum COLUMN { API_SEQNUMBER(0, "APISEQNUMBER"), SYNCDATAID(1, "SyncDataID"), EVENTTIME(2, "EventTime"), APITYPE( 3, "APIType"), TOOLTIP(4, "Tooltip"), ERRORNO(5, DBConstants.DBCOLUMN_ERROR_NUMBER), SYNCVALUE( - 6, "SyncValue"), RELEASETIME(7, "ReleaseTime"); + 6, "SyncValue"), BLOCKENDTIME(7, "BlockEndTime"); public final int index; public final String name; @@ -101,7 +101,7 @@ public class SyncEventDBTable extends DBTable { DALimit.TOOLTIP_LENGTH)); addColumn(new DBColumn(COLUMN.ERRORNO.name, DBConstants.NOT_NULL, DBConstants.DBTYPE_LONG)); addColumn(new DBColumn(COLUMN.SYNCVALUE.name, DBConstants.NOT_NULL, DBConstants.DBTYPE_LONG)); - addColumn(new DBColumn(COLUMN.RELEASETIME.name, DBConstants.NOT_NULL, + addColumn(new DBColumn(COLUMN.BLOCKENDTIME.name, DBConstants.NOT_NULL, DBConstants.DBTYPE_LONG)); setIndexColumn(COLUMN.SYNCDATAID.index); @@ -182,8 +182,8 @@ public class SyncEventDBTable extends DBTable { prep.setLong(COLUMN.ERRORNO.index + 1, (Long) (rowData.get(COLUMN.ERRORNO.index))); prep.setLong(COLUMN.SYNCVALUE.index + 1, (Long) (rowData.get(COLUMN.SYNCVALUE.index))); - prep.setLong(COLUMN.RELEASETIME.index + 1, - (Long) (rowData.get(COLUMN.RELEASETIME.index))); + prep.setLong(COLUMN.BLOCKENDTIME.index + 1, + (Long) (rowData.get(COLUMN.BLOCKENDTIME.index))); } catch (SQLException e) { e.printStackTrace(); isPrepared = false; @@ -204,7 +204,7 @@ public class SyncEventDBTable extends DBTable { row.add(rs.getString(COLUMN.TOOLTIP.index + 1)); row.add(Long.valueOf(rs.getLong(COLUMN.ERRORNO.index + 1))); row.add(Long.valueOf(rs.getLong(COLUMN.SYNCVALUE.index + 1))); - row.add(Long.valueOf(rs.getLong(COLUMN.RELEASETIME.index + 1))); + row.add(Long.valueOf(rs.getLong(COLUMN.BLOCKENDTIME.index + 1))); } catch (SQLException e) { e.printStackTrace(); return null;