11// --------------------------------------------------------------------------------------------------------------------
2- // <copyright company="Aspose" file="TrimSpreadsheetContentRequest .cs">
2+ // <copyright company="Aspose" file="AddTextRequest .cs">
33// Copyright (c) 2025 Aspose.Cells Cloud
44// </copyright>
55// <summary>
@@ -32,43 +32,41 @@ namespace Aspose.Cells.Cloud.SDK.Request
3232 using System . Text . RegularExpressions ;
3333
3434 /// <summary>
35- /// Request model for <see cref="Aspose.Cells.Cloud.SDK.Api.CellsApi.TrimSpreadsheetContent " /> operation.
35+ /// Request model for <see cref="Aspose.Cells.Cloud.SDK.Api.CellsApi.AddText " /> operation.
3636 /// </summary>
37- public class TrimSpreadsheetContentRequest : IRequestModel
37+ public class AddTextRequest : IRequestModel
3838 {
3939
4040 /// <summary>
41- /// Initializes a new instance of the <see cref="TrimSpreadsheetContentRequest "/> class.
41+ /// Initializes a new instance of the <see cref="AddTextRequest "/> class.
4242 /// </summary>
43- public TrimSpreadsheetContentRequest ( )
43+ public AddTextRequest ( )
4444 {
4545
4646 }
4747 /// <summary>
48- /// Initializes a new instance of the <see cref="TrimSpreadsheetContentRequest "/> class.
48+ /// Initializes a new instance of the <see cref="AddTextRequest "/> class.
4949 /// </summary>
5050 /// <param name="spreadsheet">Upload spreadsheet file.</param>
51- /// <param name="trimContent"></param>
52- /// <param name="trimLeading"></param>
53- /// <param name="trimTrailing"></param>
54- /// <param name="trimSpaceBetweenWordTo1"></param>
55- /// <param name="trimNonBreakingSpaces"></param>
56- /// <param name="removeExtraLineBreaks"></param>
57- /// <param name="removeAllLineBreaks"></param>
51+ /// <param name="text"></param>
52+ /// <param name="position"></param>
53+ /// <param name="selectText"></param>
54+ /// <param name="skipEmptyCells"></param>
55+ /// <param name="worksheet"></param>
56+ /// <param name="range"></param>
5857 /// <param name="outPath">(Optional) The folder path where the workbook is stored. The default is null.</param>
5958 /// <param name="outStorageName">Output file Storage Name.</param>
6059 /// <param name="region">The spreadsheet region setting.</param>
6160 /// <param name="password">The password for opening spreadsheet file.</param>
62- public TrimSpreadsheetContentRequest ( string spreadsheet , string trimContent = null , bool ? trimLeading = null , bool ? trimTrailing = null , bool ? trimSpaceBetweenWordTo1 = null , bool ? trimNonBreakingSpaces = null , bool ? removeExtraLineBreaks = null , bool ? removeAllLineBreaks = null , string outPath = null , string outStorageName = null , string region = null , string password = null )
61+ public AddTextRequest ( string spreadsheet , string text , string position , string selectText , bool ? skipEmptyCells = null , string worksheet = null , string range = null , string outPath = null , string outStorageName = null , string region = null , string password = null )
6362 {
6463 this . Spreadsheet = spreadsheet ;
65- this . trimContent = trimContent ;
66- this . trimLeading = trimLeading ;
67- this . trimTrailing = trimTrailing ;
68- this . trimSpaceBetweenWordTo1 = trimSpaceBetweenWordTo1 ;
69- this . trimNonBreakingSpaces = trimNonBreakingSpaces ;
70- this . removeExtraLineBreaks = removeExtraLineBreaks ;
71- this . removeAllLineBreaks = removeAllLineBreaks ;
64+ this . text = text ;
65+ this . position = position ;
66+ this . selectText = selectText ;
67+ this . skipEmptyCells = skipEmptyCells ;
68+ this . worksheet = worksheet ;
69+ this . range = range ;
7270 this . outPath = outPath ;
7371 this . outStorageName = outStorageName ;
7472 this . region = region ;
@@ -82,45 +80,39 @@ public TrimSpreadsheetContentRequest(string spreadsheet, string trimContent =
8280
8381
8482 /// <summary>
85- /// Gets or sets trimContent .
83+ /// Gets or sets text .
8684 /// </summary>
87- public string trimContent { get ; set ; }
85+ public string text { get ; set ; }
8886
8987
9088 /// <summary>
91- /// Gets or sets trimLeading .
89+ /// Gets or sets position .
9290 /// </summary>
93- public bool ? trimLeading { get ; set ; }
91+ public string position { get ; set ; }
9492
9593
9694 /// <summary>
97- /// Gets or sets trimTrailing .
95+ /// Gets or sets selectText .
9896 /// </summary>
99- public bool ? trimTrailing { get ; set ; }
97+ public string selectText { get ; set ; }
10098
10199
102100 /// <summary>
103- /// Gets or sets trimSpaceBetweenWordTo1 .
101+ /// Gets or sets skipEmptyCells .
104102 /// </summary>
105- public bool ? trimSpaceBetweenWordTo1 { get ; set ; }
103+ public bool ? skipEmptyCells { get ; set ; }
106104
107105
108106 /// <summary>
109- /// Gets or sets trimNonBreakingSpaces .
107+ /// Gets or sets worksheet .
110108 /// </summary>
111- public bool ? trimNonBreakingSpaces { get ; set ; }
109+ public string worksheet { get ; set ; }
112110
113111
114112 /// <summary>
115- /// Gets or sets removeExtraLineBreaks .
113+ /// Gets or sets range .
116114 /// </summary>
117- public bool ? removeExtraLineBreaks { get ; set ; }
118-
119-
120- /// <summary>
121- /// Gets or sets removeAllLineBreaks.
122- /// </summary>
123- public bool ? removeAllLineBreaks { get ; set ; }
115+ public string range { get ; set ; }
124116
125117
126118 /// <summary>
@@ -166,22 +158,39 @@ public HttpWebRequest CreateHttpRequest(string baseUri,IDictionary<string, strin
166158 // verify the required parameter 'spreadsheet' is set
167159 if ( string . IsNullOrEmpty ( this . Spreadsheet ) )
168160 {
169- throw new ApiException ( 400 , "Missing required parameter 'spreadsheet' when calling TrimSpreadsheetContent" ) ;
161+ throw new ApiException ( 400 , "Missing required parameter 'spreadsheet' when calling AddText" ) ;
162+ }
163+
164+ // verify the required parameter 'text' is set
165+ if ( string . IsNullOrEmpty ( this . text ) )
166+ {
167+ throw new ApiException ( 400 , "Missing required parameter 'text' when calling AddText" ) ;
168+ }
169+
170+ // verify the required parameter 'position' is set
171+ if ( string . IsNullOrEmpty ( this . position ) )
172+ {
173+ throw new ApiException ( 400 , "Missing required parameter 'position' when calling AddText" ) ;
174+ }
175+
176+ // verify the required parameter 'selectText' is set
177+ if ( string . IsNullOrEmpty ( this . selectText ) )
178+ {
179+ throw new ApiException ( 400 , "Missing required parameter 'selectText' when calling AddText" ) ;
170180 }
171181
172- var path = baseUri + "/cells/content/trim " ;
182+ var path = baseUri + "/cells/content/add/text " ;
173183 path = Regex
174184 . Replace ( path , "\\ *" , string . Empty )
175185 . Replace ( "&" , "&" )
176186 . Replace ( "/?" , "?" ) ;
177187
178- if ( ! string . IsNullOrEmpty ( this . trimContent ) ) path = UrlHelper . AddQueryParameterToUrl ( path , "trimContent" , this . trimContent ) ;
179- if ( this . trimLeading != null ) path = UrlHelper . AddQueryParameterToUrl ( path , "trimLeading" , this . trimLeading ) ;
180- if ( this . trimTrailing != null ) path = UrlHelper . AddQueryParameterToUrl ( path , "trimTrailing" , this . trimTrailing ) ;
181- if ( this . trimSpaceBetweenWordTo1 != null ) path = UrlHelper . AddQueryParameterToUrl ( path , "trimSpaceBetweenWordTo1" , this . trimSpaceBetweenWordTo1 ) ;
182- if ( this . trimNonBreakingSpaces != null ) path = UrlHelper . AddQueryParameterToUrl ( path , "trimNonBreakingSpaces" , this . trimNonBreakingSpaces ) ;
183- if ( this . removeExtraLineBreaks != null ) path = UrlHelper . AddQueryParameterToUrl ( path , "removeExtraLineBreaks" , this . removeExtraLineBreaks ) ;
184- if ( this . removeAllLineBreaks != null ) path = UrlHelper . AddQueryParameterToUrl ( path , "removeAllLineBreaks" , this . removeAllLineBreaks ) ;
188+ path = UrlHelper . AddQueryParameterToUrl ( path , "text" , this . text ) ;
189+ path = UrlHelper . AddQueryParameterToUrl ( path , "position" , this . position ) ;
190+ path = UrlHelper . AddQueryParameterToUrl ( path , "selectText" , this . selectText ) ;
191+ if ( this . skipEmptyCells != null ) path = UrlHelper . AddQueryParameterToUrl ( path , "skipEmptyCells" , this . skipEmptyCells ) ;
192+ if ( ! string . IsNullOrEmpty ( this . worksheet ) ) path = UrlHelper . AddQueryParameterToUrl ( path , "worksheet" , this . worksheet ) ;
193+ if ( ! string . IsNullOrEmpty ( this . range ) ) path = UrlHelper . AddQueryParameterToUrl ( path , "range" , this . range ) ;
185194 if ( ! string . IsNullOrEmpty ( this . outPath ) ) path = UrlHelper . AddQueryParameterToUrl ( path , "outPath" , this . outPath ) ;
186195 if ( ! string . IsNullOrEmpty ( this . outStorageName ) ) path = UrlHelper . AddQueryParameterToUrl ( path , "outStorageName" , this . outStorageName ) ;
187196 if ( ! string . IsNullOrEmpty ( this . region ) ) path = UrlHelper . AddQueryParameterToUrl ( path , "region" , this . region ) ;
0 commit comments