from .InstanceKey import InstanceKey

from framework import Guid

class InstanceReference:

	def __init__(self, dbid, inst_key : InstanceKey, global_id : Guid):
		self.dbid = dbid
		self.inst_key = inst_key
		self.global_id = global_id

	def get_dbid(self):
		return self.dbid
	
	def get_instance_key(self) -> InstanceKey:
		return self.inst_key
	
	def get_global_identifier(self):
		return self.global_id
	
	def __str__(self):
		return str(self.inst_key) + ' ' + str(self.global_id)

	def __repr__(self):
		return str(self.inst_key) + ' ' + str(self.global_id)