(name 'Mongo-Squeak-MartinDias.18' message 'Creating MongoTimeStamp.

As MongoDb documentation [2] states: 

"BSON has a special timestamp type for internal MongoDB use and is not associated with the regular Datetype. Timestamp values are a 64 bit value where:
- the first 32 bits are a time_t value (seconds since the Unix epoch)
- the second 32 bits are an incrementing ordinal for operations within a given second."

Now, our Mongo bindings [1] convert this MongoDb''s internal type to Pharo''s TimeStamp (i.e. the subclass of DateAndTime) with two problems: 
- it''s a wrong: the 2 parts of 32 bits are converted as 64 bits of milliseconds
- it produces a warning in latest Pharo [3]: TimeStamp has been removed so extension methods cannot be installed.


That''s why I''m creating MongoTimeStamp, and changing BSON marshaling from:

BSON>>nextTimestamp
	^self nextDateAndTime asTimeStamp

to:

BSON>>nextTimestamp
	^MongoTimeStamp value: self nextInt64

(similar for writing).


This solution was idea of Esteban and Norbert, and discussed in the issue tracker of Voyage [3]. Mongo talk team, please tell me if you don''t agree.


1: http://smalltalkhub.com/#!/~MongoTalkTeam/mongotalk
2: https://docs.mongodb.org/manual/reference/bson-types/#timestamps
3: https://github.com/estebanlm/voyage/issues/11' id 'c9e36e2b-eb48-4746-99bb-9c1d2369cc86' date '15 March 2016' time '12:54:20.293083 am' author 'MartinDias' ancestors ((name 'Mongo-Squeak-TorstenBergmann.17' message 'comment and categorize' id '46dd5821-66dc-e847-b714-f0429b91de32' date '4 March 2015' time '10:16:33.4731 am' author 'TorstenBergmann' ancestors ((name 'Mongo-Squeak-NorbertHartl.16' message 'removed useless MongoTestCase' id 'a44ad24f-1895-4ebc-872f-326f180c7c28' date '27 November 2013' time '10:42:16.944 am' author 'NorbertHartl' ancestors ((name 'Mongo-Squeak-NorbertHartl.15' message 'Fixed a bug for DateAndTime including timezone offset. Dates are calculated as milliseconds since the epoch but the epoch had local timezone. Changed so both Dates have UTC. This way calculating a difference between the dates makes sense. Added test in Mongo-BSON' id 'b20edbb8-bb7e-4184-82c6-530e6d4c7114' date '19 July 2013' time '10:48:25.452 am' author 'NorbertHartl' ancestors ((name 'Mongo-Squeak-EstebanLorenzano.13' message '- catching UTF8TextConverter (speeds time in large requests)' id 'fa7f1b5e-6b00-45a7-9f55-47cd1b36603c' date '24 November 2012' time '1:38:40.493 pm' author 'EstebanLorenzano' ancestors ((name 'Mongo-Squeak-NorbertHartl.0.12' message 'fixed UTC time for date. DateAndTime values are constructed but only the hour was converted to UTC. Calculations around midnight go wrong' id 'e99ffc44-55fd-40e2-ae9e-d2ce56c97205' date '24 February 2012' time '7:57:48 am' author 'NorbertHartl' ancestors ((name 'Mongo-Squeak-NorbertHartl.0.11' message 'fixed time offset in DateAndTime. Times are expected to be UTC' id '10bb5a84-6248-41dc-8bbf-1f68c589773c' date '17 February 2012' time '4:31:19 pm' author 'NorbertHartl' ancestors ((name 'Mongo-Squeak-JanVanDeSandt.0.10' message '- BSON conversion of DateAndTime objects was off by one day.
- Use Float new:2 instead of Float new:8 (Float class uses Words, not Bytes)' id '3980fa2b-2fec-41c8-8312-62b8d76bc769' date '17 February 2012' time '2:36:48 pm' author 'JanVanDeSandt' ancestors ((name 'Mongo-Squeak-NorbertHartl.0.9' message 'Separated handling for Timestamp and DateAndTime. Timestamps are now written as mongo timestamps that is a mongo internal type. Added support to write DateAndTime with correct mongo type. Changed epoch date generation to be UTC based to prevent time shifting between pharo and mongo db.' id 'a4566c0c-4edf-42ec-b6fd-03d1c13118fd' date '17 February 2012' time '10:30:30 am' author 'NorbertHartl' ancestors ((name 'Mongo-Squeak-EstebanLorenzano.0.8' message '-DateAndTime is a valid mongo type
-added a small optimization on UTF8 codec' id 'db10e41a-f692-4598-b760-432d2a73dde5' date '27 January 2012' time '8:19:50 pm' author 'EstebanLorenzano' ancestors ((name 'Mongo-Squeak-EstebanLorenzano.0.7' message '-performance enhancements
-bugfixes' id 'ea28479d-c9ee-4732-87a0-53c5d7a9386d' date '18 October 2011' time '9:45:08 pm' author 'EstebanLorenzano' ancestors ((name 'Mongo-Squeak-EstebanLorenzano.0.6' message '-DateAndTime modified (not working yet)' id '0659b179-357e-465b-acf7-b7b515a1a149' date '4 October 2011' time '3:16:27 pm' author 'EstebanLorenzano' ancestors ((name 'Mongo-Squeak-EstebanLorenzano.0.5' message '-smallfix' id 'cdfd2c79-e070-40c0-9a04-7bef1f191a4e' date '24 September 2011' time '8:53:19 am' author 'EstebanLorenzano' ancestors ((name 'Mongo-Squeak-klb.0.4' message 'Everything should work in both Squeak and VisualWorks now.' id 'ee7eee43-d823-4acb-bc52-092e2cc6e829' date '12 February 2010' time '11:42:50 am' author 'KentBeck' ancestors ((name 'Mongo-Squeak-klb.0.3' message 'Added MongoTestCase so TestCase subclasses could load.' id '75503748-3628-463d-8ec8-2dccdb53209c' date '12 February 2010' time '9:58:38 am' author 'KentBeck' ancestors ((name 'Mongo-Squeak-klb.0.1' message 'Initial check in of GratuitousIncompatibilities' id '666e5a6d-6c83-47e8-b79a-97ea9266d8a6' date '11 February 2010' time '11:12:35 pm' author 'KentBeck' ancestors () stepChildren ())) stepChildren ())) stepChildren ())) stepChildren ())) stepChildren ())) stepChildren ())) stepChildren ())) stepChildren ())) stepChildren ())) stepChildren ())) stepChildren ())) stepChildren ())) stepChildren ())) stepChildren ())) stepChildren ())) stepChildren ())