当前位置: 首页>>代码示例>>Python>>正文


Python Utils.get_date_from_sqlite_string方法代码示例

本文整理汇总了Python中Utils.Utils.get_date_from_sqlite_string方法的典型用法代码示例。如果您正苦于以下问题:Python Utils.get_date_from_sqlite_string方法的具体用法?Python Utils.get_date_from_sqlite_string怎么用?Python Utils.get_date_from_sqlite_string使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Utils.Utils的用法示例。


在下文中一共展示了Utils.get_date_from_sqlite_string方法的7个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。

示例1: from_sqlite_data_row

# 需要导入模块: from Utils import Utils [as 别名]
# 或者: from Utils.Utils import get_date_from_sqlite_string [as 别名]
	def from_sqlite_data_row(self, sqlite_data_row):
		id, client_mac, hostname, total_packets, last_seen_lat, last_seen_lon, seen_first_time, seen_last_time, max_metres_between_locations, number_of_times_seen = sqlite_data_row
		client = Client(client_mac)
		client.id = id
		client.hostname = hostname
		client.total_packets = int(total_packets)
		if not last_seen_lat == None:
			client.last_seen_lat = float(last_seen_lat)
			client.last_seen_lon = float(last_seen_lon)
		client.seen_first_time = Utils.get_date_from_sqlite_string(seen_first_time)
		client.seen_last_time = Utils.get_date_from_sqlite_string(seen_last_time)
		client.max_metres_between_locations = int(max_metres_between_locations)
		client.number_of_times_seen = int(number_of_times_seen)
		return client
开发者ID:darkosancanin,项目名称:wifu,代码行数:16,代码来源:Client.py

示例2: from_sqlite_data_row

# 需要导入模块: from Utils import Utils [as 别名]
# 或者: from Utils.Utils import get_date_from_sqlite_string [as 别名]
	def from_sqlite_data_row(cls, sqlite_data_row):
		id, client_mac, network_bssid, total_packets, avg_lat, avg_lon, seen_first_time, seen_last_time, max_metres_between_locations, number_of_times_seen = sqlite_data_row
		network_client = NetworkClient()
		network_client.id = id
		network_client.client_mac = client_mac
		network_client.network_bssid = network_bssid
		network_client.total_packets = int(total_packets)
		if not avg_lat == None:
			network_client.avg_lat = float(avg_lat)
			network_client.avg_lon = float(avg_lon)
		network_client.seen_first_time = Utils.get_date_from_sqlite_string(seen_first_time)
		network_client.seen_last_time = Utils.get_date_from_sqlite_string(seen_last_time)
		network_client.max_metres_between_locations = int(max_metres_between_locations)
		network_client.number_of_times_seen = int(number_of_times_seen)
		return network_client
开发者ID:darkosancanin,项目名称:wifu,代码行数:17,代码来源:NetworkClient.py

示例3: from_sqlite_data_row

# 需要导入模块: from Utils import Utils [as 别名]
# 或者: from Utils.Utils import get_date_from_sqlite_string [as 别名]
	def from_sqlite_data_row(self, sqlite_data_row):
		id, network_bssid, essid, total_packets, avg_lat, avg_lon, is_hidden, max_rate, seen_first_time, seen_last_time, max_metres_between_locations, number_of_times_seen = sqlite_data_row
		network = Network()
		network.id = id
		network.bssid = network_bssid
		network.essid = essid
		network.total_packets = int(total_packets)
		if not avg_lat == None:
			network.avg_lat = float(avg_lat)
			network.avg_lon = float(avg_lon)
		network.is_hidden = is_hidden == "1"
		network.max_rate = max_rate
		network.seen_first_time = Utils.get_date_from_sqlite_string(seen_first_time)
		network.seen_last_time = Utils.get_date_from_sqlite_string(seen_last_time)
		network.max_metres_between_locations = int(max_metres_between_locations)
		network.number_of_times_seen = int(number_of_times_seen)
		return network
开发者ID:darkosancanin,项目名称:wifu,代码行数:19,代码来源:Network.py

示例4: from_sqlite_data_row

# 需要导入模块: from Utils import Utils [as 别名]
# 或者: from Utils.Utils import get_date_from_sqlite_string [as 别名]
	def from_sqlite_data_row(cls, sqlite_data_row):
		id, file_name, date_imported = sqlite_data_row
		return ImportedHostnameFile(id, file_name, Utils.get_date_from_sqlite_string(date_imported))
开发者ID:darkosancanin,项目名称:wifu,代码行数:5,代码来源:ImportedHostnameFile.py

示例5: from_sqlite_data_row

# 需要导入模块: from Utils import Utils [as 别名]
# 或者: from Utils.Utils import get_date_from_sqlite_string [as 别名]
	def from_sqlite_data_row(cls, sqlite_data_row):
		id, client_mac, ssid, total_packets, seen_first_time, seen_last_time, number_of_times_seen = sqlite_data_row
		return ProbeRequest(id, client_mac, ssid, int(total_packets), Utils.get_date_from_sqlite_string(seen_first_time), Utils.get_date_from_sqlite_string(seen_last_time), int(number_of_times_seen))
开发者ID:darkosancanin,项目名称:wifu,代码行数:5,代码来源:ProbeRequest.py

示例6: from_sqlite_data_row

# 需要导入模块: from Utils import Utils [as 别名]
# 或者: from Utils.Utils import get_date_from_sqlite_string [as 别名]
	def from_sqlite_data_row(cls, sqlite_data_row):
		id, client_mac, avg_lat, avg_lon, seen_time, seen_in_file_name = sqlite_data_row
		return ClientLocation(id, client_mac, float(avg_lat), float(avg_lon), Utils.get_date_from_sqlite_string(seen_time), seen_in_file_name)
开发者ID:darkosancanin,项目名称:wifu,代码行数:5,代码来源:ClientLocation.py

示例7: from_sqlite_data_row

# 需要导入模块: from Utils import Utils [as 别名]
# 或者: from Utils.Utils import get_date_from_sqlite_string [as 别名]
	def from_sqlite_data_row(cls, sqlite_data_row):
		id, network_bssid, avg_lat, avg_lon, seen_time, seen_in_file_name = sqlite_data_row
		return NetworkLocation(id, network_bssid, float(avg_lat), float(avg_lon), Utils.get_date_from_sqlite_string(seen_time), seen_in_file_name)
开发者ID:darkosancanin,项目名称:wifu,代码行数:5,代码来源:NetworkLocation.py


注:本文中的Utils.Utils.get_date_from_sqlite_string方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。