Skip to content

Commit b0e83e7

Browse files
authored
Merge branch 'develop' into Models
2 parents 4b0a981 + 8d0a01f commit b0e83e7

File tree

14 files changed

+674
-254
lines changed

14 files changed

+674
-254
lines changed

Scripts/Connection/RESTConnector.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -784,7 +784,7 @@ public IEnumerator Send(string url, Dictionary<string, string> headers)
784784
};
785785
}
786786

787-
Success = postReq.responseCode == HTTP_STATUS_OK || postReq.responseCode == HTTP_STATUS_OK || postReq.responseCode == HTTP_STATUS_NO_CONTENT || postReq.responseCode == HTTP_STATUS_ACCEPTED;
787+
Success = postReq.responseCode == HTTP_STATUS_OK || postReq.responseCode == HTTP_STATUS_CREATED || postReq.responseCode == HTTP_STATUS_NO_CONTENT || postReq.responseCode == HTTP_STATUS_ACCEPTED;
788788
HttpResponseCode = postReq.responseCode;
789789
ResponseHeaders = postReq.GetResponseHeaders();
790790
Data = postReq.downloadHandler.data;

Scripts/Services/Assistant/v1/Models/DialogNodeAction.cs

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,19 @@ public enum ActionTypeEnum
4343
/// Enum SERVER for server
4444
/// </summary>
4545
[EnumMember(Value = "server")]
46-
SERVER
46+
SERVER,
47+
48+
/// <summary>
49+
/// Enum CLOUD_FUNCTION for cloud_function
50+
/// </summary>
51+
[EnumMember(Value = "cloud_function")]
52+
CLOUD_FUNCTION,
53+
54+
/// <summary>
55+
/// Enum WEB_ACTION for web_action
56+
/// </summary>
57+
[EnumMember(Value = "web_action")]
58+
WEB_ACTION
4759
}
4860

4961
/// <summary>

Scripts/Services/Assistant/v2/Models/DialogNodeAction.cs

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,19 @@ public enum ActionTypeEnum
4040
/// Enum server for server
4141
/// </summary>
4242
[EnumMember(Value = "server")]
43-
server
43+
server,
44+
45+
/// <summary>
46+
/// Enum WEB_ACTION for web-action
47+
/// </summary>
48+
[EnumMember(Value = "web-action")]
49+
web_action,
50+
51+
/// <summary>
52+
/// Enum CLOUD_FUNCTION for cloud-function
53+
/// </summary>
54+
[EnumMember(Value = "cloud-function")]
55+
cloud_function
4456
}
4557

4658
/// <summary>

Scripts/Services/Discovery/v1/Discovery.cs

Lines changed: 284 additions & 24 deletions
Large diffs are not rendered by default.

Scripts/Services/Discovery/v1/Models/LogQueryResponseResult.cs

Lines changed: 1 addition & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -27,28 +27,6 @@ namespace IBM.Watson.DeveloperCloud.Services.Discovery.v1
2727
[fsObject]
2828
public class LogQueryResponseResult
2929
{
30-
/// <summary>
31-
/// The type of log entry returned.
32-
///
33-
/// **query** indicates that the log represents the results of a call to the single collection **query**
34-
/// method.
35-
///
36-
/// **event** indicates that the log represents a call to the **events** API.
37-
/// </summary>
38-
public enum DocumentTypeEnum
39-
{
40-
/// <summary>
41-
/// Enum query for query
42-
/// </summary>
43-
[EnumMember(Value = "query")]
44-
query,
45-
/// <summary>
46-
/// Enum _event for event
47-
/// </summary>
48-
[EnumMember(Value = "event")]
49-
_event
50-
}
51-
5230
/// <summary>
5331
/// The type of event that this object respresents. Possible values are
5432
///
@@ -91,7 +69,7 @@ public enum ResultTypeEnum
9169
/// **event** indicates that the log represents a call to the **events** API.
9270
/// </summary>
9371
[fsProperty("document_type")]
94-
public DocumentTypeEnum? DocumentType { get; set; }
72+
public string DocumentType { get; set; }
9573
/// <summary>
9674
/// The type of event that this object respresents. Possible values are
9775
///
Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
/**
2+
* Copyright 2018 IBM Corp. All Rights Reserved.
3+
*
4+
* Licensed under the Apache License, Version 2.0 (the "License");
5+
* you may not use this file except in compliance with the License.
6+
* You may obtain a copy of the License at
7+
*
8+
* http://www.apache.org/licenses/LICENSE-2.0
9+
*
10+
* Unless required by applicable law or agreed to in writing, software
11+
* distributed under the License is distributed on an "AS IS" BASIS,
12+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13+
* See the License for the specific language governing permissions and
14+
* limitations under the License.
15+
*
16+
*/
17+
18+
using FullSerializer;
19+
using System.Collections.Generic;
20+
21+
namespace IBM.Watson.DeveloperCloud.Services.Discovery.v1
22+
{
23+
/// <summary>
24+
/// Tokenization dictionary describing how words are tokenized during ingestion and at query time.
25+
/// </summary>
26+
[fsObject]
27+
public class TokenDict
28+
{
29+
/// <summary>
30+
/// An array of tokenization rules. Each rule contains, the original `text` string, component `tokens`, any
31+
/// alternate character set `readings`, and which `part_of_speech` the text is from.
32+
/// </summary>
33+
[fsProperty("tokenization_rules")]
34+
public List<TokenDictRule> TokenizationRules { get; set; }
35+
}
36+
37+
}

Scripts/UnitTests/TestLanguageTranslatorV2.cs.meta renamed to Scripts/Services/Discovery/v1/Models/TokenDict.cs.meta

Lines changed: 2 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,52 @@
1+
/**
2+
* Copyright 2018 IBM Corp. All Rights Reserved.
3+
*
4+
* Licensed under the Apache License, Version 2.0 (the "License");
5+
* you may not use this file except in compliance with the License.
6+
* You may obtain a copy of the License at
7+
*
8+
* http://www.apache.org/licenses/LICENSE-2.0
9+
*
10+
* Unless required by applicable law or agreed to in writing, software
11+
* distributed under the License is distributed on an "AS IS" BASIS,
12+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13+
* See the License for the specific language governing permissions and
14+
* limitations under the License.
15+
*
16+
*/
17+
18+
using FullSerializer;
19+
using System.Collections.Generic;
20+
21+
namespace IBM.Watson.DeveloperCloud.Services.Discovery.v1
22+
{
23+
/// <summary>
24+
/// An object defining a single tokenizaion rule.
25+
/// </summary>
26+
[fsObject]
27+
public class TokenDictRule
28+
{
29+
/// <summary>
30+
/// The string to tokenize.
31+
/// </summary>
32+
[fsProperty("text")]
33+
public string Text { get; set; }
34+
/// <summary>
35+
/// Array of tokens that the `text` field is split into when found.
36+
/// </summary>
37+
[fsProperty("tokens")]
38+
public List<string> Tokens { get; set; }
39+
/// <summary>
40+
/// Array of tokens that represent the content of the `text` field in an alternate character set.
41+
/// </summary>
42+
[fsProperty("readings")]
43+
public List<string> Readings { get; set; }
44+
/// <summary>
45+
/// The part of speech that the `text` string belongs to. For example `noun`. Custom parts of speech can be
46+
/// specified.
47+
/// </summary>
48+
[fsProperty("part_of_speech")]
49+
public string PartOfSpeech { get; set; }
50+
}
51+
52+
}

Scripts/Services/Discovery/v1/Models/TokenDictRule.cs.meta

Lines changed: 11 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
/**
2+
* Copyright 2018 IBM Corp. All Rights Reserved.
3+
*
4+
* Licensed under the Apache License, Version 2.0 (the "License");
5+
* you may not use this file except in compliance with the License.
6+
* You may obtain a copy of the License at
7+
*
8+
* http://www.apache.org/licenses/LICENSE-2.0
9+
*
10+
* Unless required by applicable law or agreed to in writing, software
11+
* distributed under the License is distributed on an "AS IS" BASIS,
12+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13+
* See the License for the specific language governing permissions and
14+
* limitations under the License.
15+
*
16+
*/
17+
18+
using FullSerializer;
19+
using System.Runtime.Serialization;
20+
21+
namespace IBM.Watson.DeveloperCloud.Services.Discovery.v1
22+
{
23+
/// <summary>
24+
/// Object describing the current status of the tokenization dictionary.
25+
/// </summary>
26+
[fsObject]
27+
public class TokenDictStatusResponse
28+
{
29+
/// <summary>
30+
/// Current tokenization dictionary status for the specified collection.
31+
/// </summary>
32+
[fsProperty("status")]
33+
public string Status { get; set; }
34+
/// <summary>
35+
/// The type for this dictionary. Always returns `tokenization_dictionary`.
36+
/// </summary>
37+
[fsProperty("type")]
38+
public string Type { get; set; }
39+
}
40+
41+
}

0 commit comments

Comments
 (0)