@@ -33,80 +33,63 @@ public sealed class SubText : TextEnvelope
33
33
/// <summary>
34
34
/// Extracted subtext from a <see cref="string"/>.
35
35
/// </summary>
36
- /// <param name="text">text to extreact from</param>
37
- /// <param name="strt">where to start</param>
38
- public SubText ( String text , int strt ) : this ( new LiveText ( text ) , strt )
36
+ public SubText ( String text , int start ) : this ( new LiveText ( text ) , start )
39
37
{ }
40
38
41
39
/// <summary>
42
40
/// Extracted subtext from a <see cref="string"/>.
43
41
/// </summary>
44
- /// <param name="text">text to extract from</param>
45
- /// <param name="strt">where to start</param>
46
- /// <param name="end">where to end</param>
47
- public SubText ( String text , int strt , int end ) : this (
42
+ public SubText ( String text , int start , int length ) : this (
48
43
new LiveText ( text ) ,
49
- strt ,
50
- end
44
+ start ,
45
+ length
51
46
)
52
47
{ }
53
48
54
49
/// <summary>
55
50
/// Extracted subtext from a <see cref="IText"/>.
56
51
/// </summary>
57
- /// <param name="text">text to extract from</param>
58
- /// <param name="strt">where to start</param>
59
- public SubText ( IText text , int strt ) : this (
52
+ public SubText ( IText text , int start ) : this (
60
53
text ,
61
- new Live < Int32 > ( strt ) ,
62
- new Live < Int32 > ( ( ) => text . AsString ( ) . Length - strt )
54
+ new Live < Int32 > ( start ) ,
55
+ new Live < Int32 > ( ( ) => text . AsString ( ) . Length - start )
63
56
)
64
57
{ }
65
58
66
59
/// <summary>
67
60
/// Extracted subtext from a <see cref="IText"/>.
68
61
/// </summary>
69
- /// <param name="text">text to extract from</param>
70
- /// <param name="strt">where to start</param>
71
- /// <param name="end">where to end</param>
72
- public SubText ( IText text , int strt , int end ) : this (
62
+ public SubText ( IText text , int start , int length ) : this (
73
63
text ,
74
- new Live < Int32 > ( strt ) ,
75
- new Live < Int32 > ( end )
64
+ new Live < Int32 > ( start ) ,
65
+ new Live < Int32 > ( length )
76
66
)
77
67
{ }
78
68
79
69
/// <summary>
80
70
/// Extracted subtext from a <see cref="IText"/>.
81
71
/// </summary>
82
- /// <param name="text">text to extract from</param>
83
- /// <param name="strt">where to start encapsulated in a scalar</param>
84
- /// <param name="len">where to end encapsulated in a scalar</param>
85
- /// <param name="live">should the object build its value live, every time it is used?</param>
86
72
public SubText (
87
73
IText text ,
88
- Live < Int32 > strt ,
89
- Live < Int32 > len ,
74
+ Live < Int32 > start ,
75
+ Live < Int32 > length ,
90
76
bool live = false
91
77
) : this (
92
78
text ,
93
- ( ) => strt . Value ( ) ,
94
- ( ) => len . Value ( )
79
+ ( ) => start . Value ( ) ,
80
+ ( ) => length . Value ( )
95
81
)
96
82
{ }
97
83
98
84
/// <summary>
99
85
/// Extracted subtext from a <see cref="IText"/>.
100
86
/// </summary>
101
- /// <param name="text">text to extract from</param>
102
- /// <param name="strt">where to start encapsulated in a scalar</param>
103
- /// <param name="len">where to end encapsulated in a scalar</param>
104
- public SubText ( IText text , Func < Int32 > strt , Func < Int32 > len ) : base ( ( ) =>
87
+ public SubText ( IText text , Func < Int32 > start , Func < Int32 > length ) : base ( ( ) =>
105
88
{
106
89
return
107
90
text . AsString ( ) . Substring (
108
- strt ( ) ,
109
- len ( )
91
+ start ( ) ,
92
+ length ( )
110
93
) ;
111
94
} ,
112
95
false
0 commit comments