Unix and Linux Discussions Tagged with end |
|
Thread / Thread Starter |
Last Post |
Replies |
Views |
Forum |
|
|
|
2 |
6,729 |
UNIX for Beginners Questions & Answers |
|
|
|
16 |
13,902 |
UNIX for Beginners Questions & Answers |
|
|
|
5 |
7,215 |
UNIX for Beginners Questions & Answers |
|
|
|
10 |
12,725 |
AIX |
|
|
|
2 |
3,120 |
Shell Programming and Scripting |
|
|
|
10 |
5,458 |
Shell Programming and Scripting |
|
|
|
4 |
3,196 |
Shell Programming and Scripting |
|
|
|
9 |
2,037 |
Shell Programming and Scripting |
|
|
|
5 |
2,744 |
Shell Programming and Scripting |
|
|
|
6 |
2,965 |
Shell Programming and Scripting |
|
|
|
0 |
1,138 |
Security Advisories (RSS) |
|
|
|
0 |
2,038 |
Cartoons for Geeks |
|
|
|
0 |
1,766 |
Complex Event Processing RSS News |
|
|
|
3 |
18,592 |
Shell Programming and Scripting |
|
|
|
5 |
18,949 |
Solaris |
|
|
|
0 |
1,350 |
UNIX and Linux RSS News |
|
|
|
0 |
1,385 |
UNIX and Linux RSS News |
|
|
|
9 |
55,267 |
UNIX for Dummies Questions & Answers |
|
|
|
14 |
8,017 |
UNIX for Dummies Questions & Answers |
|
|
|
12 |
30,417 |
UNIX for Dummies Questions & Answers |
|
|
|
2 |
16,157 |
UNIX for Advanced & Expert Users |
|
|
|
4 |
116,835 |
Shell Programming and Scripting |
|
|
|
4 |
28,951 |
UNIX for Dummies Questions & Answers |
|
|
|
4 |
72,584 |
UNIX for Dummies Questions & Answers |
|
|
|
4 |
4,338 |
UNIX for Advanced & Expert Users |
|
|
|
1 |
4,349 |
Programming |
|
|
|
3 |
13,035 |
Shell Programming and Scripting |
|
|
|
4 |
6,652 |
UNIX for Advanced & Expert Users |
|
|
|
1 |
3,484 |
UNIX for Dummies Questions & Answers |
|
|
|
4 |
3,680 |
UNIX for Dummies Questions & Answers |
|
|
|
4 |
8,284 |
UNIX for Dummies Questions & Answers |
|
|
|
2 |
3,952 |
UNIX for Advanced & Expert Users |
|
|
|
2 |
4,985 |
UNIX for Dummies Questions & Answers |
|
|
|
1 |
3,526 |
Programming |
|
|
|
2 |
3,991 |
Programming |
|
|
|
5 |
15,335 |
UNIX for Advanced & Expert Users |
|
|
|
2 |
9,679 |
UNIX for Advanced & Expert Users |
|
|
|
7 |
7,057 |
UNIX for Dummies Questions & Answers |
|
|
|
1 |
3,374 |
UNIX for Dummies Questions & Answers |
|
|
|
1 |
12,116 |
UNIX for Dummies Questions & Answers |
gets(n) Tcl Built-In Commands gets(n)
__________________________________________________________________________________________________________________________________________________
NAME
gets - Read a line from a channel
SYNOPSIS
gets channelId ?varName?
_________________________________________________________________
DESCRIPTION
This command reads the next line from channelId, returns everything in the line up to (but not including) the end-of-line character(s), and
discards the end-of-line character(s). If varName is omitted the line is returned as the result of the command. If varName is specified
then the line is placed in the variable by that name and the return value is a count of the number of characters returned.
If end of file occurs while scanning for an end of line, the command returns whatever input is available up to the end of file. If chan-
nelId is in nonblocking mode and there is not a full line of input available, the command returns an empty string and does not consume any
input. If varName is specified and an empty string is returned in varName because of end-of-file or because of insufficient data in non-
blocking mode, then the return count is -1. Note that if varName is not specified then the end-of-file and no-full-line-available cases
can produce the same results as if there were an input line consisting only of the end-of-line character(s). The eof and fblocked commands
can be used to distinguish these three cases.
SEE ALSO
file(n), eof(n), fblocked(n)
KEYWORDS
blocking, channel, end of file, end of line, line, nonblocking, read
Tcl 7.5 gets(n)