version

Comparing two version numbers

懵懂的女人 提交于 2019-12-05 05:22:09
How can I compare two Version number strings? For example: 3.1.1 and 3.1.2.5.4 Now I need to find out if 3.1.2.5.4 is higher than 3.1.1 but I don't know how to do this. Can anybody help me? Thanks in advance! Sample Code : NSString* v1 = @"3.1.1"; NSString* v2 = @"3.1.2.5.4"; if ([v1 compare:v2 options:NSNumericSearch] == NSOrderedDescending) { NSLog(@"%@ is greater than %@",v1,v2); } From the Apple Documentation for Comparing and sorting strings . Paras Yes, you can compare the versions, please refer the code below: public class Comparision { string ver1, ver2; public static void main(String

Include Http-4.2.1 with Android App

烈酒焚心 提交于 2019-12-05 04:35:56
问题 I wish to include the latest version of Http with my Android App, which is 4.2.1. Now wish to download the library from Apache website and include it in the libs folder and then to the build path of my app. On including Http - 4.2.1, I got the following output in the logcat 08-28 02:42:40.917: D/dalvikvm(25641): DexOpt: 'Lorg/apache/http/client/ResponseHandler;' has an earlier definition; blocking out 08-28 02:42:40.917: D/dalvikvm(25641): DexOpt: 'Lorg/apache/commons/codec/Decoder;' has an

Multiple Rails versions for multiple projects

余生长醉 提交于 2019-12-05 04:27:44
问题 I'd like to use Rails 2.2.2 for one project and Rails 2.3.2 for another. Both are installed. What is rails _2.2.2_ --version supposed to do? I've read that it makes 2.2.2 the working version -- that is, the version that will be used from that point on. But when I check rails --version , I get Rails 2.3.2 . So, I also want to know what rails --version tells me; is it just the latest version of Rails that I have or is it the version that will be used for rake s? I know about RVM. Is that the

Which version of Entity Framework is used by my project?

我与影子孤独终老i 提交于 2019-12-05 04:25:09
I have a project using Entity Framework, but I am not sure which version of EF I am using. According to the Microsoft version history EF5 will install itself: If you create a new model using the Entity Framework Designer in Visual Studio 2012, the EF5 NuGet package will be installed to your project and the generated code will make use of EF5. However I did not create the EF-part of the project, but got it from version control (TFS). Now I am not sure how to determine if I have EF5. If I right-click on the References folder of the project and select Manage NuGet Packages, it show EF5 with an

How to update version of Python?

ぐ巨炮叔叔 提交于 2019-12-05 03:56:36
I had Python2.6 on my Windows 7 and I just installed Python2.7. As a result I have "C:\Python26" and "C:\Python27". My problem is that system still tries to use the old version. For example if I type Python --version I get "Python 2.6.4". Or, if I try to install "numpy" it find the old version and does not allow me to manually change it to the new version. I tried to check system environment variables to find out if there is Python2.6 (to replace it by Python2.7) but I did not find anything like that. You need to change Python path to the new version. http://docs.python.org/using/windows.html

Just installed SASS, but can't get its version

喜夏-厌秋 提交于 2019-12-05 03:54:19
I installed SASS from the terminal, just gem install sass . And I see it says "Successfully installed sass-3.2.9." However, when I then do sass --version or sass --v I get this error: -bash: sass: command not found The only thing I can think of is, when I was doing the Git tutorials on Tuts+ I ran into a local vs. global issue or I had to edit a bash_profile file. This is what is inside the bash_profile file inside my user directory: export PATH="/usr/local/bin:$PATH" Any thoughts or tips on why I can't get the version of SASS or Compass I just installed? (I can only get ruby --version .) Leon

How do JavaScript versions correlate to ECMAScript versions?

拥有回忆 提交于 2019-12-05 03:23:15
For example, [].map was "implemented in JavaScript 1.6." Is that an ES5 method? How does the 1.6 correlate to an ECMAScript version? There aren't really strict correspondences between the version numbers Mozilla uses and the ECMAScript standard's version numbers. There's a table on Wikipedia that might be what you're looking for -- you'll see that JavaScript 1.6 corresponds to ECMAScript 3 and then some additional extensions. [].map specifically was standardized in ECMAScript 5, but to my understanding, the feature was first introduced by Firefox before the ECMAScript 5 standard was even

How to efficiently version records in an SQL database

时间秒杀一切 提交于 2019-12-05 02:47:14
问题 In at least one application, I have the need to keep old versions of records in a relational database. When something should be updated, instead a new copy would be added and the old row would be marked as not current. When something should be deleted, it should instead be marked as not current or deleted. There is a simple use case of this: New versions of a record can only be added at the current time, superseding one row each. This can be used for archiving previous records when saving new

How to keep edit history of large string field in relational database

有些话、适合烂在心里 提交于 2019-12-05 02:31:54
N.B. I think answers are likely to be design-focused and therefore basically implementation agnostic, but I'm using Java+Hibernate with Postgres if there's some particularly well-suited solution using those technologies. I have a table with a particular field which will hold large strings, let's say blog posts which on average are +10000 characters. In my app, you can edit blog posts as many times as you like, and the latest version will always be displayed instantly after an update. However, the app needs to keep a full version history of these edits, so they can be viewed. An obvious

Get FileDescription (ProgramName) from .exe

不羁的心 提交于 2019-12-05 02:30:26
问题 I am developing an activity tracker for my development work in Eclipse (with Java). I now have the program's path and the duration i spent in it. e.g.: 7min C:\Program Files (x86)\Internet Explorer\iexplore.exe and 10min C:\Program Files\Microsoft Office\Office14\OUTLOOK.EXE I now want to know the name of the program. In C# I get it like this: System.Diagnostics.FileVersionInfo versionInfo = System.Diagnostics.FileVersionInfo.GetVersionInfo(file); return (versionInfo.FileDescription == string