Hi guys, given a dataset in plain text, for example:
==Events==
* [[312]] – [[Constantine the Great]] is said to have received his famous [[Battle of Milvian Bridge
* [[710]] – [[Saracen]] invasion of [[Sardinia]].
* [[939]] – [[Edmund I of England|Edmund I]] succeeds [[Athelstan of England|Athelstan]] as [[King of England]].
*[[1275]] – Traditional founding of the city of [[Amsterdam]].
*[[1524]] – [[Italian Wars]]: The French troops lay siege to [[Pavia]].
*[[1553]] – Condemned as a [[Heresy|heretic]], [[Michael Servetus]] is [[burned at the stake]] just outside [[Geneva]].
*[[1644]] – [[Second Battle of Newbury]] in the [[English Civil War]].
*[[1682]] – [[Philadelphia]], [[Pennsylvania]] is founded.
I would like to get NSDictionaryanother form of collection, so that I can display the year (number on the left) in the excerpt (text on the right). So here is what a pattern is:
*[[YEAR]] – THE_TEXT
Although I would like the excerpt to be plain text, that is, without wiki markup, so no ones [[are set. In fact, this can be difficult using aliases such as [[Edmund I of England|Edmund I]].
I don’t know much about regular expressions, so I have a few questions. Should I try to "decorate" the data first? For example, deleting the first line that will always be ==Events==, and delete the entries [[and ]]?
, , : ? , , * [[710]] [[Saracen]] invasion of [[Sardinia]]. NSArrays.
NSArray [[]] ( , , 530 ..), * [[710]] 710.
NSArray, , [[some_article|alias]], - [[alias]], [[ ]]?
? ? , , ?
! .
: , . , , . wiki , , . !