OLD | NEW |
(Empty) | |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. |
| 4 |
| 5 package org.chromium.chrome.browser.historyreport; |
| 6 |
| 7 /** |
| 8 * Represents entry in delta file. Each entry is a log of action that happened t
o history data. It |
| 9 * can be addition or deletion of an URL. |
| 10 */ |
| 11 public class DeltaFileEntry { |
| 12 /** |
| 13 * Unique id of this entry. Order of two entries can be determined by compar
ing their seqNos. |
| 14 * Smaller happened first. |
| 15 */ |
| 16 public final long seqNo; |
| 17 /** |
| 18 * Type of the action represented by this entry. Can be 'add' or 'del'. |
| 19 */ |
| 20 public final String type; |
| 21 /** |
| 22 * ID which identifies the URL targeted by the action represented by this en
try. |
| 23 * It's shorter than 257 characters. |
| 24 */ |
| 25 public final String id; |
| 26 /** |
| 27 * URL targeted by the action represented by this entry. |
| 28 */ |
| 29 public final String url; |
| 30 /** |
| 31 * Score of the URL targeted by the action represented by this entry. |
| 32 * It's used in search ranking. |
| 33 */ |
| 34 public final int score; |
| 35 /** |
| 36 * Title of the URL targeted by the action represented by this entry. |
| 37 */ |
| 38 public final String title; |
| 39 |
| 40 /** |
| 41 * Part of URL which will be used as a search key in index. |
| 42 */ |
| 43 public final String indexedUrl; |
| 44 |
| 45 public DeltaFileEntry(long seqNo, String type, String id, String url, int sc
ore, String title, |
| 46 String indexedUrl) { |
| 47 this.seqNo = seqNo; |
| 48 this.type = type; |
| 49 this.id = id; |
| 50 this.url = url; |
| 51 this.score = score; |
| 52 this.title = title; |
| 53 this.indexedUrl = indexedUrl; |
| 54 } |
| 55 |
| 56 @Override |
| 57 public String toString() { |
| 58 return "DeltaFileEntry[" + seqNo + ", " + type + ", " + id + ", " + url
+ ", " + title |
| 59 + "]"; |
| 60 } |
| 61 } |
OLD | NEW |