 	}
 }
 
+enum CooprActionType:String
+{
+	case SPLIT = "SPLIT"
+	case DIVIDEND = "DIVIDEND"
+}
+
+struct CoorpAction:Printable
+{
+	let date:NSDate
+	let type:CooprActionType
+	let value:Double
+	
+	var description:String
+		{
+			let vstr = String(format:"%.6f", value)
+			return "\(Int(date.timeIntervalSince1970))-\(vstr)-\(type.rawValue)"
+	}
+}
+
+func createActionMap(list:[CoorpAction]?, #formatter:NSDateFormatter)->[String:CoorpAction]
+{
+	var map:[String:CoorpAction] = [:]
+	if list == nil
+	{
+		return map
+	}
+	
+	for i in 0..<list!.count
+	{
+		let key = formatter.stringFromDate(list![i].date)
+		map[key] = list![i]
+	}
+	
+	return map
+}
+
 func parseQuote(rawlist:[String])
 {
 	var ready = false

	}
}

if !all
{
	fetchQuote(getQuoteRequest(ticket, interval: interval, numOfDays: numOfDays, exchange:exchange))

	
	var formatter = NSDateFormatter()
	formatter.dateFormat = "yyyy-MM-dd,HH:mm:SS"
	
	var dmap:[String:CoorpAction] = createActionMap(dividends, formatter: formatter)
	var split = 1.0
	
	var time = 0
	for i in 0..<rawlist.count
