Граф коммитов

15 Коммитов

Автор SHA1 Сообщение Дата
TJ Lambert bd4501ac88
[naturallanguage] Add nullability to (generated and manual) bindings (#14741)
* adding nullability changes

* throwing better exceptions

* using is null

* address Rolf and Manuel nullability changes

Co-authored-by: TJ Lambert <tjlambert@microsoft.com>
2022-04-26 09:50:51 -05:00
Rolf Bjarne Kvinge 2972e1b715
Fix some whitespace issues in various files. (#12399)
* Remove BOM
* Add EOL at end of file.
2021-08-11 10:06:46 +02:00
Manuel de la Pena 0f7bc75e50 Merge branch 'xcode12.2' into main-xcode12.2 2020-11-17 11:09:15 -05:00
Alex Soto 9d1988a3c8
[tests][xcode12.2] Fix xammac tests (#9935)
* [tests][xcode12.2] Fix xammac tests

* Update tests/common/TestRuntime.cs

Co-authored-by: Rolf Bjarne Kvinge <rolf@xamarin.com>

* [xammac] Avoid multiple #if statements

* [xammac] Fix missing cases amd reduce amount of changes

Co-authored-by: Rolf Bjarne Kvinge <rolf@xamarin.com>
2020-10-21 17:12:48 -04:00
Manuel de la Pena dcb0c93ab0 [Xcode12] Bring xcode 12 changes into main. 2020-09-23 16:05:22 -04:00
Sebastien Pouliot 25c361f43e
[xcode12][intro] Fix running introspection on old macOS versions (#9638)
Most fixes are inside Intents. Some types were not available on macOS
and marked as such, except it backfired.

* Adding `[NoMac]` on `XAMCORE_4_0` was fine
* Adding `[Obsolete]` outside `XAMCORE_4_0` was fine
* Removing the `[Mac (x,y)]` was not quite fine. It's true (since it was never on macOS) but removing it means it default to the oldest (10.9) macOS version we support. This is what the introspection tests were expecting.

Adding an `[Obsoleted (..., 10,0, ...)]` solve this.
2020-09-15 12:59:21 -04:00
Sebastien Pouliot 38fb1018a7
[naturallanguage] Update for Xcode 12 beta 2 (#9133) 2020-07-20 16:15:00 -04:00
Rolf Bjarne Kvinge 2995cd086a
[tests] Update tests to make native type vs normal type comparison explicit (#9097)
We've modified our NUnitLite to special-case the native types, so that they
can easily be compared with the standard types, but that doesn't work anymore
when switching to the official NUnit[Lite], so change all asserts to
explicitly convert whenever needed.
2020-07-17 08:48:09 +02:00
Rolf Bjarne Kvinge f8f7de004c
[tests] Fix introspection and xammac tests on Catalina. (#7200)
* [tests] Adjust NaturalLanguage.EmbeddingTest to cope with non-existent embeddings. Fixes xamarin/maccore#2011.

Fixes https://github.com/xamarin/maccore/issues/2011.

* [tests] Fix typo test on macOS 10.15. Fixes #7116.

Fixes https://github.com/xamarin/xamarin-macios/issues/7116.
2019-10-10 08:35:38 +02:00
Sebastien Pouliot 61c8af15d1
[naturallanguage] Update for Xcode 11 beta 1 (#6741)
No change in beta 2 to 5

* Run EmbeddingTest.Vector test on iOS and macOS only

reference: rdar 44948030

> Engineering has the following feedback for you: The tagging
> depends on the NLP assets being present on the device. The
> assets get downloaded through OTA. OTA download for NLP assets
> does not exist on watchOS and tvOS currently…only on iOS and
> macOS. It is conceivable that the assets got downloaded when you
> were on WiFi at a later point. So, the tagging should work.
2019-08-12 11:07:15 -04:00
monojenkins eb77564659 [xcode11] Fix NLLanguageRecognizer crash (#6732)
The dispose of `nslang` was happening outside of the check if `nslang` is null. This was causing a crash when trying to recognise a string that contains just one number.
2019-08-07 13:08:27 -04:00
Sebastien Pouliot 0304219723
[tests] Fix some tests to succeed when run on macOS 10.14 (#5057)
Public bots were updated today.

Fixes https://github.com/xamarin/maccore/issues/1106
Fixes https://github.com/xamarin/maccore/issues/1107
2018-10-31 08:32:36 -04:00
Sebastien Pouliot 0841238e29
[naturallanguage] Fix helper API for `NLTagger.GetTag` and cleanup/fix other API. Fixes #4774 (#4782)
* Move `NLTag` to static class (instead of enum) since it's not used in API, except along NSString. Fixes https://github.com/xamarin/xamarin-macios/issues/4774
* Add new member to `NLLanguage` to avoid `ArgumentNullException` when it has not been evaludated (API returns `null`), see unit tests;
* Add `[Params]` to `NLTagger` constructors so they are easier to use (no need to create the array in source);
* Fix `GetTag` so it returns (`out`) the `NSRange`, it's natively a `NSRangePointer`;
* Fix `GetTag[s]` API with changes to `NLTag` de-enumification;
* Add unit tests
2018-09-11 08:40:42 -04:00
Manuel de la Pena 92d6e94707 [NaturalLanguage] Change return type to use double instead on nuint. Fixes #4642 (#4654)
The docs or headers do not specify the exact type. Using double to be
sure.

Issue: https://github.com/xamarin/xamarin-macios/issues/4642
2018-08-20 21:44:24 -04:00
Manuel de la Pena f77f44940e
[NaturalLanguage] Added the new framework for Xcode10. (#4236) 2018-06-14 19:21:44 +02:00