
311 Md. 85 (1987)
532 A.2d 1066
LEONARD JOSEPH MAUS
v.
STATE OF MARYLAND. NATHAN DONNELL WILKES
v.
STATE OF MARYLAND. RICHARD ALLEN EDGE
v.
STATE OF MARYLAND.
Nos. 19, 54 and 66, September Term, 1987.
Court of Appeals of Maryland.
November 4, 1987.
Nancy S. Forster, Asst. Public Defender (Alan H. Murrell, Public Defender, on brief), Baltimore, for Maus and Wilkes. Sherrie B. Glasser, Asst. Public Defender, Baltimore, on the brief for Maus.
Jose' Felipe' Anderson, Asst. Public Defender (Alan H. Murrell, Public Defender, on brief), Baltimore, for Edge.
Mary Ellen Barbera, Asst. Atty. Gen. (J. Joseph Curran, Jr., Atty. Gen., on brief), Baltimore, for appellee State.
Argued before MURPHY, C.J., and ELDRIDGE, COLE, RODOWSKY, McAULIFFE, ADKINS and BLACKWELL, JJ.
ADKINS, Judge.
The three cases we now consider present a common question: When a probationer has admitted violations of probation, the probation has been revoked, and a sentence of incarceration imposed, does § 12-302(e) of the Courts and Judicial Proceedings Art. (1984 Repl.Vol.) require that further review be by application for leave to appeal, or does that statute impose that procedure only upon review of a judgment entered after a plea of guilty in a criminal case? The Court of Special Appeals believed that § 12-302(e) applies in the probation context. We do not agree and, therefore, reverse the judgment of the Court of Special Appeals in each case.[1]

I. Section 12-302(e) of the Courts Article
In the Circuit Court for Worcester County, Leonard Joseph Maus was charged with violations of probation. He admitted them, presenting evidence and argument only as to disposition. The court found that he had violated probation and imposed the full five year sentence that it had originally suspended in favor of that probation. Essentially the same events occurred with respect to Nathan Donnell Wilkes in the Circuit Court for Prince George's County (original ten year sentence reimposed) and to Richard Allen Edge in the Circuit Court for Prince George's County (original five year sentence reimposed). Each of them noted a timely appeal to the Court of Special Appeals. In each case the State moved to dismiss the appeal on the ground that under the circumstances, § 12-302(e) allowed no appeal as of right, but instead permitted only an application for leave to appeal. In each case the Court of Special Appeals granted the motion to dismiss. In each case we granted a petition for the writ of certiorari. We now explain why the intermediate appellate court misread the statute.
Section 12-301 of the Courts Art. provides a broad right of appeal: "Except as provided in § 12-302, a party may appeal from a final judgment entered in a civil or criminal case by a circuit court." Section 12-302(e) limits that right. Enacted by Ch. 295, Acts of 1983, it reads:
Section 12-301 does not permit an appeal from a final judgment entered following a plea of guilty in a circuit court. Review of such a judgment shall be sought by application for leave to appeal.
The words of this statute strongly suggest that it applies only to criminal cases. Guilty pleas are not filed in civil cases, and a revocation of probation proceeding is, in Maryland, "firmly established as a civil action...." Chase v. State, 309 Md. 224, 239, 522 A.2d 1348, 1355 (1987). More specifically, in Howlett v. State, 295 Md. 419, 423-424, 456 A.2d 375, 377-378 (1983), we explained that the Maryland rules dealing with guilty pleas and how they may be tendered and accepted simply do not apply in probation revocation cases. Howlett's teaching has now been embodied in the rules. Rule 4-346(c) explicitly states that "[t]he provisions of Rule 4-242 [dealing with pleas in criminal cases] do not apply to an admission of violation of conditions of probation." It is, of course, just such admissions that we have before us.[2]
The State, nevertheless, asserts that the purpose of § 12-302(e) was and is to lessen the workload of the Court of Special Appeals, and that this laudable purpose will be advanced by applying the statute to dispositions following admissions of probation violations. It further argues that an admission of violation in a probation revocation case is in many respects the functional equivalent of a guilty plea in a criminal case. In both instances, for example, it asserts that the facts are established and not reviewable on appeal. "Nothing remains," after the plea or admission "but to give judgment and determine punishment." Sutton v. State, 289 Md. 359, 364, 424 A.2d 755, 758 (1981) (discussing effect of guilty plea).
While we are not persuaded that the analogy between guilty pleas and probation violation admissions is necessarily as perfect as the State would have it, it is at least conceivable that the legislature might have intended to extend § 12-302(e) to the latter situation, despite the inaptness of the language used, if that was the desired result. There is no doubt that divination of the legislative goal or objective is basic to the task of statutory construction, Kaczorowski v. City of Baltimore, 309 Md. 505, 513, 525 A.2d 628, 632 (1987), and that in seeking to ascertain that goal or objective, we often should "pursue the context of statutory language" by reviewing what may in general be characterized as "legislative history." Kaczorowski, 309 Md. at 514-515, 525 A.2d at 632-633. "The purpose, in short, determined in light of the statute's context, is the key." Id. 309 Md. at 516, 525 A.2d at 633. We turn, then, to consideration of the legislative history of § 12-302(e).
As we have observed, the measure was enacted by Ch. 295, Acts of 1983. But its roots extend further back than the 1983 session of the General Assembly.
On 6 October 1977 the Legislative Committee of the Maryland Judicial Conference[3] "considered [Chief] Judge Gilbert's [recommendation] that further review after a guilty plea at the circuit court level should be by application for leave to appeal" and "[t]he committee voted to propose legislation in this regard." Md.Jud.Conf., Minutes of 6 Oct. 1977 meeting of the Legislative Committee at 4. Shortly thereafter, the Executive Secretary of the Judicial Conference wrote Delegate Owens, Chairman of the House Judiciary Committee, about a bill to "provide for an application for leave to appeal ... in connection with a conviction entered on a guilty plea in the circuit court." Executive Secretary's letter of 21 December 1977 to Chairman Owens at 2 [emphasis supplied]. Legislation was introduced. Senate Bill 617 and House Bill 881, both of 1978, contained language almost identical to that of present § 12-302(e). Neither bill emerged from committee.
The same results occurred at the 1979 legislative session, when S.B. 326 and H.B. 887 both died in committee. The Senate Judicial Proceedings Committee file, however, contains the following comment on S.B. 326:
The Bill provides that review of final judgment in cases when the Defendant entered a guilty plea shall be on petition ... praying [for] leave to appeal and not by right as now exists. This procedure... is aimed at reducing the number of frivolous appeals after conviction following the Defendant's entry of a guilty plea.

Senate Judicial Proceedings Committee file on S.B. 326 (1979) [emphasis supplied]. This document, like the Executive Secretary's 1977 letter, has a distinctly "criminal" sound, with its mention not only of "guilty plea" but also of "conviction."
The Judicial Conference at that point temporarily suspended further activity on the proposal. Minutes of 30 July 1979 meeting of Criminal Law Subcommittee of the Legislative Committee at 2. But the concept was resuscitated by the Commission to Study the Judicial Branch of Government.
That Commission (often denominated the "Fisher Commission" in recognition of its Chairman Charles O. Fisher, Esq.) was created pursuant to Resolution 25 of 1981. As directed by that Resolution, the Commission studied "all aspects of the operations of the Judicial Branch of government" including the operations of the appellate courts. In its report, it identified "the major problem of the appellate level" as "the workload of the Court of Special Appeals." Report of the Commission to Study the Judicial Branch of Government (1982) at 14 [hereinafter Report]. After a perceptive analysis of this problem and various possible solutions, it rejected major proposals for structural and jurisdictional changes, emphasizing instead procedural and administrative approaches. Report at 15-37. It did, however, identify "one narrow area for the addition of discretionary review by the Court of Special Appeals." Report at 28. It recommended that
review of a conviction following a plea of guilty should be ... made discretionary. Such a proposal was made by the Judicial Conference in 1979.
The Commission reasoned:
A guilty plea is an admission of guilt. When sentence is imposed following such a plea, the factual details of the criminal offense and the issues of guilt or innocence are usually no longer issues for appellate review. Generally, the only appellate issues are whether the plea was knowingly and voluntarily entered with full appreciation of the potential consequences, whether a particular plea bargain was followed, and whether the sentence was lawful. These issues can readily and properly be handled through the application for leave to appeal process. Adoption of this recommendation would affect an estimated 100 cases annually (about 5.8 percent of the court's 1981 Term filings).
Report at 28 [emphasis supplied; footnotes omitted].
We again note the vocabulary of the criminal law  "conviction," "guilty plea," "sentence," "guilt or innocence," "plea bargain." It is difficult to believe that the 12 distinguished judges and lawyers who comprised three-quarters of the Commission did not understand the meaning of these terms and did not use them in their technical senses.
Supporting this view is the last sentence quoted from the Report. The Commission, as we have seen, proposed only "one narrow area" of change in appellate jurisdiction. It noted that only about 100 Court of Special Appeals cases would have been affected by the proposal during the 1981 term. This statistic also indicates that the Commission was thinking in terms of guilty pleas in criminal cases, for a statistical universe that extended to admissions in revocation of probation cases would no doubt have been larger.[4]
In any case, the Report was distributed to all members of the General Assembly and the document's recommendations produced, among other things, the introduction of S.B. 540 and H.B. 1117 at the 1983 legislative session. The Judicial Proceedings and Judiciary Committees held a joint hearing. S.B. 540 received a favorable report and eventually became Ch. 295. Significantly, the Judicial Proceedings Committee's report on S.B. 540 describes the "Legislative Intent" of the bill in these terms: "The purpose of this bill is to reduce the work load of the Appellate Courts by limiting access to the Court of Special Appeals in criminal cases involving guilty pleas." [Emphasis supplied.]
This history demonstrates that the legislative goal was indeed to reduce the workload of the intermediate appellate court, but to do so with respect to a carefully limited class of cases: those in which a circuit court judge had accepted a guilty plea in a criminal case. The language of the statute is perfectly consistent with that goal. We hold that § 12-302(e) does not restrict the statutory right of appeal in revocation of probation cases.
We reverse the judgment of the Court of Special Appeals in each of these three cases. In Edge's case, this means that he is entitled to pursue his properly-noted appeal in that court. Since both Maus and Wilkes have presented additional issues to us, involving alleged errors at the circuit court level, we must give further consideration to their cases.

II. Maus's Case: Art. 27 § 638C(a)
Maus's original sentencing (so far as this case is concerned) was in January 1982. On that occasion his five-year sentence for storehouse breaking was suspended in favor of a five-year period of probation. One condition of probation was that Maus enroll in and complete the Second Genesis, Inc., drug rehabilitation program. The record indicates that Maus had both alcohol and CDS problems, with the former predominating. Maus entered Second Genesis's facility in Alexandria, Virginia, in April 1982. He resided there until March, 1984, when he was authorized to leave Second Genesis and live in the community. He was discharged by Second Genesis in June 1984, having successfully completed the program. In August he was arrested in Prince George's County and charged with driving while intoxicated. He was convicted of this offense and later (in Baltimore City) of storehouse breaking.
For these (and other lesser) violations of the standard conditions of probation, Maus was tried on several occasions in the Circuit Court for Worcester County, the most recent one in September 1986.[5] As we have recounted, the outcome was revocation of probation and imposition of the original five year sentence.
At the 1986 revocation hearing, Maus presented evidence of his successful completion of the Second Genesis program. He also introduced evidence about the nature of the program. In essence, this showed that Second Genesis provides "a structured, supervised environment seven days a week, twenty-four hours a day." The main therapeutic technique is "[e]ncounter group therapy...." During the first 12 months of the program, "the residents' entire routine takes place within the facility." Residents are required to perform jobs in categories which include: "kitchen, dining room, maintenance and administration." After successful completion of the first in-facility year, residents are permitted to secure jobs in the community. During the initial stages of this second phase of treatment, they continue to reside in the facility. Later on, however, the residents move into the community, returning only to attend group meetings at Second Genesis.
On the basis of this evidence, Maus argues that his stay at Second Genesis was the functional equivalent of imprisonment. Therefore, he contends, credit should be awarded for time spent at the Second Genesis facility by virtue of the provisions of art. 27, § 638C(a). The trial judge did not agree; neither do we.
Art. 27, § 638C(a) in pertinent part provides:
Any person who is convicted and sentenced shall receive credit against the term of a definite or life sentence or credit against the minimum and maximum terms of an indeterminate sentence for all time spent in the custody of any state, county or city jail, correctional institution, hospital, mental hospital or other agency as a result of the charge for which the sentence is imposed or as a result of the conduct on which the charge is based.... [Emphasis supplied.]
The subject of credit against a sentence for time spent in a halfway house, a residential treatment center, or similar facility has been variously treated by our sister states. A number of jurisdictions have chosen to allow credit for time spent in facilities of this type. In People v. Rodgers, 79 Cal. App.3d 26, 144 Cal. Rptr. 602 (1978), the court held that credit for time spent in a halfway house must be awarded where probation is revoked and an actual sentence imposed. There, the probationer had, as a condition of probation, spent time in a halfway house known as Delancey Street Foundation. The relevant statute, however, expressly included halfway houses among the creditable facilities, and the court took cognizance of legislative history to the effect that the statute was intended to provide credit for stays in any live-in drug rehabilitation program, whether public or private. Id. at 30-32, 144 Cal. Rptr. at 604-606.[6]
A more sweeping decision is Lock v. State, 609 P.2d 539 (Alaska 1980). There, the Supreme Court of Alaska decided that a probation-conditioned sojourn in a residential rehabilitation program not unlike that of Second Genesis qualified for credit under a statute allowing credit for "time spent in custody." Id. at 545. A more recent Alaska case elaborates on the reasoning underlying its decision in Lock:
[I]ncarcerative facilities share a number of common characteristics: their residents are invariably sent there by court order; the facilities require residency, and residency requirements are sufficiently stringent to involve a definite element of confinement; residents of the facilities are subject to twenty-four hour physical custody or supervision; any periods during which residents may be permitted to leave the facility are expressly limited both as to time and purpose; while in the facility, residents are under a continuing duty to conform their conduct to institutional rules and to obey orders of persons who have immediate custody over them; and residents are subject to sanctions if they violate institutional rules or orders and to arrest if they leave the facility without permission.
Nygren v. State, 658 P.2d 141, 146 (Alaska 1983). Many of these criteria apply to Second Genesis.
In accord with Lock v. State, supra, is People v. Stange, 91 Mich. App. 596, 283 N.W.2d 806 (1979). There, the court awarded credit for time spent in a drug rehabilitation center pursuant to a statute requiring "credit ... for ... time served in jail prior to sentencing." Id. at 600-601, 283 N.W.2d at 808.
A similar result was reached in Commonwealth v. Usher, 264 Pa.Super. 435, 399 A.2d 1129 (1979), although on somewhat different facts. There, the court awarded credit for time spent in a residential drug and alcohol treatment facility where the applicable statute mandated "credit for any days spent in custody," id. at 438, 399 A.2d at 1130; the court relied upon what it regarded as significant "restraint" on liberty at the facility. The restraints included hourly head counts and immediate notification of police, probation authorities and the court if persons left the facility. Id. at 437, 399 A.2d at 1130. These restraints appear to be greater than those imposed upon Maus.
Other jurisdictions have declined to award credit for time spent in a drug rehabilitation center or similar facility as a condition of probation. New Jersey, for instance, has refused to award credit for time in a drug rehabilitation facility where the applicable statute mandated credit "for any time [the defendant] has spent in custody in jail or in a state hospital." See State v. Reyes, 207 N.J. Super. 126, 141-145, 504 A.2d 43, 51-53 (1986). [Emphasis supplied.] Emphasizing that participants were not locked in, and departure from the facility was not the criminal offense of escape, the court reasoned that "[a]ttendance at such a program is not the equivalent of `custody' so long as there are no physical restraints and a participant retains the option to leave without committing an additional crime." Id. at 144, 504 A.2d at 52.
Interpreting similar statutes under analogous circumstances, several courts have reached results that are in accord with State v. Reyes, supra. See People v. Radar, 652 P.2d 1085, 1086-1087 (Colo. 1982) (no credit awarded under statute granting credit for time spent in "confinement" where defendant spent time at a halfway house); Pennington v. State, 398 So.2d 815, 817 (Fla. 1981) (denying credit to defendant for time spent at a drug rehabilitation facility under statute allowing "credit for all ... time spent in the county jail") [emphasis in original]; State v. Freeman, 95 Ill. App.3d 297, 299-300, 50 Ill.Dec. 846, 848-849, 420 N.E.2d 163, 165-166 (1981) (no credit given for time in drug treatment facility under statute allowing credit "for time spent in custody"); State v. Babcock, 226 Kan. 356, 361-362, 597 P.2d 1117, 1122 (1979) (defendant awarded no credit for stay in halfway house as a condition of probation where statute mandated that credit be given for time "spent ... in jail ..."); Grant v. State, 99 Nev. 149, 150-151, 659 P.2d 878, 879 (1983) (defendant who had spent time at residential drug treatment facility was not "in confinement" within the meaning of Nev.Rev.Stat. § 176.055 because he was free to leave the facility at any time); People ex rel. Robinson v. Warden, New York City Correctional Institution for Women, 58 A.D.2d 559, 560, 396 N.Y.S.2d 19, 20 (1977) (defendant was not "in custody" while at a live-in drug treatment program within the meaning of N.Y.Penal Law § 70.30 and thus was not entitled to credit against her sentence); State v. Nagle, 23 Ohio St.3d 185, 186-188, 492 N.E.2d 158, 159-160 (1986) (statute mandating "reduction of ... sentence by the total number of days the prisoner was confined" held not to require credit for time spent in a drug rehabilitation facility as a condition of probation) [emphasis added]; State v. Bell, 369 N.W.2d 140, 143-144 (S.D. 1985) (no credit awarded for time in an alcohol treatment program under statute allowing credit for "imprisonment. . . in the county jail or state penitentiary ...") [emphasis supplied]; and State v. Cobb, 135 Wis.2d 181, 183-185, 400 N.W.2d 9, 10-11 (1986) (court denied credit to defendant for his stay at drug abuse treatment center on the grounds that he was not "in custody" within the meaning of Wis. Stat. § 973.155(1)(a)).
Thus, as these cases show us, the majority of courts construing sentence-credit statutes similar to § 638C(a) do not award credit for time spent in a drug treatment center or similar facility as a condition of probation. The cases are of limited value to us, however, since each construes a particular statute in light of local legislative history or judicial gloss. Although we must try to approach § 638C(a) in a similar fashion (i.e., by examining its own legislative history), we are nevertheless cognizant of the majority approach.
In Fleeger v. State, 301 Md. 155, 165, 482 A.2d 490, 495 (1984), we identified one purpose of the statute as "to ensure that a defendant receive as much credit as possible for time spent in custody as is consistent with constitutional and practical considerations." In that case, however, we did not have occasion to construe the language now before us.
The critical words in the statute are "time spent in the custody of any state, county or city jail, correctional institution, hospital, mental hospital, or other agency...." The word "custody" can have a great variety of meanings and so can the words "other agency." A mere reading of the statute does not make clear whether a legislative purpose was to allow credit for time spent in a private, tightly-controlled facility such as Second Genesis. Unfortunately, moreover, the files of the Department of Legislative Reference contain nothing that helps explain the key language.
Section 638C(a) was enacted by Ch. 735, Acts of 1974. The title of Ch. 735 tells us no more than the statutory language does. One amendment made during its passage, however, may contain a clue. When Ch. 735 was introduced as H.B. 650 (1974), the phrase on which we now focus referred to "time spent under the supervision or under the custody of any state, county or city jail" etc. The words "under the supervision or" were deleted by amendment. That deletion may have been designed to emphasize the incarcerative nature of the custody that would qualify for credit  mere supervision would not be enough. That is, the "custody" had to be involuntary and pursuant to a court commitment to a public institution.
Turning more generally to the language of § 638C(a), it bears some resemblance to § 3.6(a) of the ABA Standards for Criminal Justice  Standards Relating to Sentencing Alternatives and Procedures (Approved Draft 1968).[7] Indeed it appears that the ABA Standards served as a model for § 638C(a). See Joint Committee of Maryland Judicial Conference and Maryland State Bar Association to Implement the ABA Standards for Criminal Justice, Report and Recommendations (1974) at pp. 32-34 (discussing credit to be awarded to a criminal defendant for time served with reference to § 3.6 of the ABA Standards). In its Report the Joint Committee noted that § 70.30(3) of the proposed Criminal Code of the State of Maryland Commission on Criminal Law (otherwise known as the "Brune Commission") "generally conforms with the [ABA] Standards, § 3.6." Joint Committee Report and Recommendations, supra, at p. 33. The Joint Committee gave its endorsement to the proposal. Id. at pp. 33-34. Thus, the ABA Standards will provide important guidance to us in our interpretation of § 638C(a).
Comment b to § 3.6 best illustrates the scope of that standard. It provides the following in pertinent part:
It also should be noted that subsection (a) is designed to assure that credit is awarded in instances where special treatment is imposed as a result of the conduct which underlies the criminal charge. The "pending sentence" language would clearly include, for example, any time spent in a diagnostic facility for the purpose of compiling a report under a provision like section 4.6., infra.... To shift to another context, the Advisory Committee would agree with the provision in Title I of the Narcotics Rehabilitation Act of 1966 to the effect that credit be given for time spent as the result of a civil commitment for addiction if criminal proceedings based on conduct which led to the commitment are subsequently resumed. ... The language "or the underlying conduct on which such a charge is based" is intended to secure this result.
ABA Standards  Standards Relating to Sentencing Alternatives and Procedures, supra, comment b, at pp. 192-193. [Emphasis supplied; citations omitted.] Title I of the Narcotics Rehabilitation Act provides as follows:
(a) If the United States district court believes that an eligible individual is an addict, the court may advise him at his first appearance or thereafter at the sole discretion of the court that the prosecution of the criminal charge will be in abeyance if he elects to submit to an immediate examination to determine whether he is an addict and is likely to be rehabilitated through treatment. In offering an individual an election, the court shall advise him that if he ... is determined to be an addict who is likely to be rehabilitated, he will be civilly committed to the Surgeon General for treatment.... [Emphasis supplied.]
Narcotics Rehabilitation Act, 28 U.S.C. § 2902(a) (1977). The Act also makes escape while civilly committed to such a facility punishable as a criminal offense. Id., § 2902(e); Escape and Rescue Act, 18 U.S.C. § 751 (1979). Thus, under ABA Standard 3.6, a criminal defendant civilly committed to a drug treatment facility during the pendency of criminal proceedings must be credited for time spent in the facility if the proceedings later resume, conviction results and an actual sentence is imposed.
Therefore, under § 3.6(a) of the ABA Standards, credit may be awarded for time spent in a drug treatment facility. But that may occur only when the defendant is civilly committed to the treatment facility and when, in cases of unauthorized departure, he or she is guilty of the crime of escape.[8]
Maryland courts, too, have authority to civilly commit criminal defendants to treatment facilities. See Md. Code Ann. (1982), § 8-510 of the Health-Gen. Art. (allowing the court to commit a criminal defendant to the Department of Health and Mental Hygiene for "evaluation and treatment"); Md. Code Ann. (1982), § 9-630 of the Health-Gen. Art. (authorizing civil commitment of criminal defendant to the Drug Abuse Administration for treatment); Md. Code Ann. (1982, 1987 Cum.Supp.), § 12-111 of the Health-Gen. Art. (requiring the court to civilly commit a criminal defendant following "a verdict of not criminally responsible" to the Department of Health and Mental Hygiene for "inpatient care or treatment"). Furthermore, unauthorized departure from any one of the State-run institutions to which an individual is committed for the most part constitutes the criminal offense of escape. See Md. Code Ann. (1982 Repl. Vol., 1987 Cum.Supp.), art. 27, § 139.
Residence in a facility such as Second Genesis is not the type of custody envisioned by the drafters of § 3.6(a) of the ABA Standards. Moreover, residence in such a facility is not custody within the context of § 638C(a). Indeed, a court cannot impose imprisonment as a condition of probation. Stone v. State, 43 Md. App. 329, 336, 405 A.2d 345, 349 (1979); cf. Matthews v. State, 304 Md. 281, 284, 498 A.2d 655, 656 (1985) (sentencing court has no authority to order period of probation to begin while defendant is actually serving sentence for same offense). And while acceptance of stringent conditions of probation (as opposed to incarceration) may pose a hard choice, it is a choice nevertheless. The probationer must consent to the conditions, Md. Code Ann. (1982 Repl.Vol., 1987 Cum.Supp.), art. 27, § 641, as Maus did in this case. Indeed, Maus expressly requested that he be permitted to participate in the Second Genesis program. Finally, a court cannot commit anyone to a facility like Second Genesis. One may be admitted there only by consent of the facility. Second Genesis is in this way distinguished from jail, correctional institutions and public hospitals.[9]
The legislature, then, did not intend to provide credit for time spent in facilities like Second Genesis. Maus asserts, however, that if the statute is so construed, it violates his constitutional rights (1) against multiple punishment for the same offense, (2) to equal protection of the law, and (3) to due process of law.[10]
As to double jeopardy, the fifth amendment's prohibition against multiple punishment for the same offense, North Carolina v. Pearce, 395 U.S. 711, 717, 89 S.Ct. 2072, 2076, 23 L.Ed.2d 656, 665 (1969), applicable to the states through the fourteenth amendment, Benton v. Maryland, 395 U.S. 784, 794, 89 S.Ct. 2056, 2062, 23 L.Ed.2d 707, 716 (1969), is not implicated here. As a general rule, there is no double jeopardy prohibition against revocation of probation and imposition of punishment. Donaldson v. State, 305 Md. 522, 530-531, 505 A.2d 527, 532 (1986); Clipper v. State, 295 Md. 303, 313, 455 A.2d 973, 978 (1983). See United States v. DiFrancesco, 449 U.S. 117, 137, 101 S.Ct. 426, 437, 66 L.Ed.2d 328, 346 (1980). Nor is the rule otherwise on the facts of this case.
When Maus was sentenced in 1982 the sentence consisted of several elements: a period of incarceration, execution of which was suspended, and a period of probation, subject to a number of conditions. But it was, nevertheless, a single sentence. Assuming, as Maus might wish us to, that each of these elements was, in some sense, punishment, they all added up to but a single punishment, a punishment that included residence at Second Genesis as well as the possibility of incarceration in the conventional sense, in the event of a violation of a condition of probation. When Maus, by his own acts, violated probation, he created the condition that made it possible to implement the incarceration element. This was not, however, multiple punishment for the original offense; it was merely activation of a conditionally-suspended portion of the original punishment. State v. Lohnes, 266 N.W.2d 109, 113-114 (S.D. 1978). See also Ralston v. Robinson, 454 U.S. 201, 220 n. 14, 102 S.Ct. 233, 245 n. 14, 70 L.Ed.2d 345, 361 n. 14 (1981) (because Youth Corrections Act contemplates possibility of sentence modification when a subsequent offense is committed, increased sentence after subsequent offense is not prohibited multiple punishment).
As to equal protection, we decline to address this issue. Although Maus did make an equal protection claim in his brief,[11] he did not raise the issue in his petition for certiorari, nor was it presented in our order granting the writ. Consequently, the issue is not before us, and we need not address it. See Rule 813(a); Allgood v. State, 309 Md. 58, 82, 522 A.2d 917, 929 (1987); Md. Nat'l Cap. P. & P. Comm'n v. Crawford, 307 Md. 1, 36-37, 511 A.2d 1079, 1097 (1986); McCray v. State, 305 Md. 126, 136-137, 501 A.2d 856, 861 (1985).
Finally, Maus claims that the lower court's failure to grant him credit for time spent at Second Genesis was a violation of substantive due process. In support of this claim, Maus cites State v. Jonason, 292 N.W.2d 730 (Minn. 1980). In Jonason, the court held that it was "fundamentally unfair" to fail to credit the defendant for his nine-month live-in at a drug treatment facility as a condition of probation. Id. at 736. Maus argues in essence that "fundamental fairness" dictates credit for his stay at Second Genesis based upon the fact that while there, he was subjected to substantial restraints on his liberty. We find this argument without merit and, therefore, reject it.
Although Second Genesis is a tightly controlled facility, it is neither a prison nor any similar public facility. It is not unfair for the State, in an effort to minimize "dead time," Fleeger, 301 Md. at 165, 482 A.2d at 495, to allow credit for involuntary, court-required imprisonment or treatment, but not to allow it for residential treatment which, as here, has been requested by the individual who subsequently seeks credit for the time spent in the treatment facility. In short, the trial court was correct when it failed to credit Maus for the time that he spent at Second Genesis.[12]
Having said that, we are constrained to add a few more words. Section 638C(a) demonstrates a legislative policy of fairness  a desire to give a person the benefit of prison time, or similar incarceration, actually served as a result of conduct for which a sentence of incarceration is eventually imposed. That policy is commendable in its effort to avoid inequitable stacking of punishment that could result in actual service of a period of imprisonment longer than the sentence imposed by the trial court.
A trial court has many options when it decides that a probationer has violated one or more conditions of probation. These options vary from continuing the probation to reimposing the full remaining term of a suspended sentence. See Smitley v. State, 61 Md. App. 477, 481-485, 487 A.2d 315, 317-319 (1985). The court's discretion must guide it as it chooses among the options, looking at both society's interests and those of the offender. Lee v. State, 307 Md. 74, 78-81, 512 A.2d 372, 374-375 (1986); Scott v. State, 238 Md. 265, 275, 208 A.2d 575, 580 (1965). As it does so, a factor that should be considered is whether the violator has in fact spent substantial time under circumstances that in many respects are similar to incarceration. A court should weigh those circumstances, and may, although it does not necessarily have to, give appropriate credit for them, when it decides what disposition to make of a probation violator.
The record in this case shows that the Circuit Court for Worcester County did not believe it could weigh at all Maus's period of residency at Second Genesis. In other words, it failed to exercise its discretion to take that factor into account when it decided what disposition was appropriate following Maus's violation of probation. This was error. When a court must exercise discretion, failure to do so is error, and ordinarily requires reversal. Colter v. State, 297 Md. 423, 427-431, 466 A.2d 1286, 1289-1290 (1983). See also Hart v. Miller, 65 Md. App. 620, 627, 501 A.2d 872, 876 (1985). Maus is entitled to a disposition fashioned after the court has given whatever weight it deems proper to the Second Genesis residency, balanced against other pertinent information in the record. The circuit court's judgment must be vacated and the case remanded for that purpose.

III. Wilkes's Case: The Right to Counsel and Rule 4-215
Like Maus, appellant Wilkes presents an issue in addition to the one we have discussed in Part I of this opinion.[13] He contends that at his probation revocation hearing he was tried in violation of a constitutional right to counsel, and that the trial court failed to make a proper determination of waiver of that right pursuant to Rule 4-215(a). We place these arguments in factual context.
In April 1983 the Circuit Court for Prince George's County convicted Wilkes of housebreaking. He received a ten-year sentence, suspended in favor of five years' probation. In February 1986 he was charged with violating various conditions of probation by failing to report to his agent, to work or attend school regularly, to get permission before changing his address, and to get permission before changing his job. On 27 June 1986 Wilkes appeared before Judge James Magruder Rea and was advised of his right to counsel, the availability of the Public Defender if Wilkes could not afford to retain counsel, and his right to represent himself. Judge Rea explained, among other things:
And in the event private counsel or the Public Defender have not entered their appearance for you within fifteen days from today, a plea of not guilty will be entered for you, pursuant to Rule 4-242,[[14]] ... and your case will be scheduled for trial without counsel and if you appear for trial without counsel, the Court could determine that you have waived your right to counsel by neglecting or refusing to retain counsel or to make timely application to the Public Defender ..., and in that event, the case would proceed with your being unrepresented by counsel. [Emphasis supplied].
Wilkes indicated a desire to be represented by the Public Defender. Judge Rea thereupon set the matter for hearing on 11 July.
On 3 July the Public Defender advised the court that Wilkes did "not qualify for the services of the Public Defender because of ... [his] income." When Wilkes reappeared in court on 11 July, Judge Rea advised him at length about the importance of representation by counsel. The judge reiterated the right to counsel at state expense "if you are indigent." Then he noted that the Public Defender had said Wilkes did not qualify for that office's services. Judge Rea thereupon asked if Wilkes wanted "to try the Gray Panel."[15] Wilkes responded affirmatively and Judge Rea said
All right, we're going to show him referred to the Gray Panel. If you don't get somebody by the 25th you have to be back.
Wilkes did not have counsel by the 25th and was back in court, this time before Judge Robert Woods, who again informed him of his right to counsel and that
[i]f you appear on that day of trial without an attorney the Court could determine that you have waived your right to an attorney by neglecting or refusing to obtain an attorney or to make timely application to the Public Defender, and in that event your case would proceed to trial without you being represented by a lawyer. [Emphasis supplied.]
Wilkes admitted he had no lawyer; he said "I have to go to the Gray Defender, your Honor." At that point, Joseph Gallagher, a lawyer from the Public Defender's Office, interjected: "If he wants to wait here and talk to me, I have a note here that I would accept a fee arrangement, your Honor." Judge Woods told Wilkes to speak to Mr. Gallagher. The docket shows that Wilkes was referred to the Public Defender.
What, if anything, was discussed between Wilkes and Gallagher the record does not disclose. It does disclose that on 29 October 1986, Wilkes, unaccompanied by counsel, appeared before Judge Arthur Ahalt for trial of the probation violation charges. Things moved rapidly:
THE CLERK: Criminal Trial 82-1484, State of Maryland versus Nathan Donnell Wilkes.
MR. CHAZEN [Asst. State's Attorney]: Good Morning, Your Honor.
THE COURT: Mr. Wilkes, do you admit or deny the allegations in the petition for violation of probation?
MR. WILKES: No, Your Honor, I do not deny them.
* * * * * *
[Wilkes thereupon attempted to deny, or at least to explain or justify the violations, saying he was working, he had not changed his address, and that his failure to report had been caused by sickness and other problems.]
THE COURT: Mr. Sollod [probation agent], what is your recommendation in this case?
MR. SOLLOD: Simply put, Your Honor, I don't think Mr. Wilkes is a good candidate for probation because he will not maintain contact.
THE COURT: All right. I agree with you. [Mr. Sollod then expounded on Wilkes's probation history: "no serious crimes ..., but he had not maintained steady contact." Wilkes had attended school and "had a period where he did well" but "he's been a nuisance, if anything." Judge Ahalt also permitted Wilkes to allocute, during which Wilkes again sought to explain that his failure to report had been caused by conditions beyond his control  conditions that no longer existed.]
THE COURT: All right. Based on your admission of violation I will find you in violation. I sentence you to the original sentence of ten years in the Department of Corrections.
He's in your custody, Mr. Sheriff.
MR. WILKES: Ten years? Ten years?
There is no doubt that Wilkes was unrepresented by counsel at the violation of probation hearing. There is no doubt that Wilkes had a constitutional right to counsel at that hearing. Vincenti v. State, 309 Md. 601, 604, 525 A.2d 1072, 1074 (1987); State v. Bryan, 284 Md. 152, 158 n. 5, 395 A.2d 475, 479 n. 5 (1978). There is no doubt that Rule 4-215 was applicable, since it "mandates a procedure specifically designed to protect that right...." Vincenti, 309 Md. at 604, 525 A.2d at 1074. But, parries the State, Wilkes waived by inaction his right to counsel.
The State's waiver argument is premised on the fact that on at least three occasions prior to trial, Wilkes was advised of his right to counsel, the importance of counsel, the availability of the Public Defender and the Gray Panel, and of the consequences of his failure to obtain counsel by the trial date. We do not question that such a waiver may occur. See Crowder v. State, 305 Md. 654, 656-657, 506 A.2d 240, 241 (1986); Leonard v. State, 302 Md. 111, 126-127, 486 A.2d 163, 170-171 (1985). The problem here is first, that the trial judge made no finding of a knowing and intelligent waiver of this right, based upon Wilkes's inaction or otherwise. And more fundamentally, the judge did not comply with the requirements of Rule 4-215(d). The rule provides:
In a circuit court, if a defendant who has appeared before that court pursuant to section (a) of this Rule appears without counsel on the date set for a hearing or trial and indicates a desire to have counsel, the court shall permit the defendant to explain the appearance without counsel. If the court finds that there is a meritorious reason for the defendant's appearance without counsel, the court shall continue the action to a later time and advise the defendant that if counsel does not enter an appearance by that time, the action will proceed to trial with the defendant unrepresented by counsel. If the court finds that there is no meritorious reason for the defendant's appearance without counsel, the court may determine that the defendant has waived counsel by failing or refusing to obtain counsel and may proceed with the hearing or trial.
When Wilkes appeared for trial on 29 October 1986, he had been told, more than once, that if he was unrepresented on that occasion, the court could determine that he had waived his right to counsel. He was not told, however, that the court could only make that determination if it found that Wilkes had "no meritorious reason" for appearing without counsel, a determination that could not be made until the hearing or trial date. But, the "no meritorious reason" finding cannot conceivably be made without some type of inquiry. Thus, before the trial court makes a finding of waiver, it must permit the defendant to explain the appearance without counsel.
Wilkes, then, came to the trial aware (legally speaking) that he would be able to explain why he was then unrepresented. It is true that he did not expressly indicate to Judge Ahalt on that occasion "a desire to have counsel." But, as our earlier quotes from the trial transcript demonstrate, he never had a chance to do so. And in point of fact, at every prior appearance, Wilkes had shown that he wanted to be represented by counsel. Indeed, at the last of those appearances, it seemed that the Public Defender might agree to represent him.
Why Wilkes did not have a lawyer on 29 October we do not know. We do not know because the judge did not ask him. In failing to do so, the judge violated Rule 4-215(d) and because of that violation, forestalled his own ability to make a proper waiver determination.[16] Since there was no waiver determination, Wilkes was deprived of his right to counsel. The judgment must be vacated.[17]Vincenti, supra, 309 Md. at 604, 525 A.2d at 1074.

IV. Summary
In each of these three cases, we hold that § 12-302(e) of the Courts Art. does not apply to a revocation of probation proceeding in which the defendant admits the fact of his violation of probation. In such a case the defendant whose probation is revoked has a statutory right to appeal to the Court of Special Appeals. Consequently, we reverse the judgments of the Court of Special Appeals dismissing these appeals.
In Maus's case, for the reasons stated in Part II of this opinion, we remand to the Court of Special Appeals with directions to vacate the judgment of the Circuit Court for Worcester County and to remand to that court for further proceedings consistent with this opinion. In Wilkes's case, for the reasons stated in Part III, we remand to the Court of Special Appeals with directions to vacate the judgment of the Circuit Court for Prince George's County and to remand to that court for further proceedings consistent with this opinion. Edge's case is remanded to the Court of Special Appeals so that it may proceed in the normal course of appeals to that court.
IN MAUS V. STATE, NO. 19, SEPT. TERM, 1987, JUDGMENT OF THE COURT OF SPECIAL APPEALS REVERSED. CASE REMANDED TO THAT COURT WITH DIRECTIONS TO VACATE THE JUDGMENT OF THE CIRCUIT COURT FOR WORCESTER COUNTY AND TO REMAND TO THAT COURT FOR FURTHER PROCEEDINGS CONSISTENT WITH THIS OPINION. COSTS TO BE PAID BY THE COUNTY COMMISSIONERS FOR WORCESTER COUNTY.
IN WILKES V. STATE, NO. 54, SEPT. TERM, 1987, JUDGMENT OF THE COURT OF SPECIAL APPEALS REVERSED. CASE REMANDED TO THAT COURT WITH DIRECTIONS TO VACATE THE JUDGMENT OF THE CIRCUIT COURT FOR PRINCE GEORGE'S COUNTY AND TO REMAND TO THE CIRCUIT COURT FOR FURTHER PROCEEDINGS CONSISTENT WITH THIS OPINION. COSTS TO BE PAID BY PRINCE GEORGE'S COUNTY, MARYLAND.
IN EDGE V. STATE, NO. 66, SEPT. TERM, 1987, JUDGMENT OF THE COURT OF SPECIAL APPEALS REVERSED AND CASE REMANDED TO THAT COURT FOR FURTHER PROCEEDINGS CONSISTENT WITH THIS OPINION. COSTS TO BE PAID BY PRINCE GEORGE'S COUNTY, MARYLAND.
NOTES
[1]  In Maus v. State, No. 19, and in Wilkes v. State, No. 54, additional issues are presented. We shall address them in due course. In Edge v. State, No. 66, however, the only question presented is the one we have just stated.
[2]  In point of fact, Maus, through counsel, told the Circuit Court for Worcester County: "We would not contest and enter a plea of guilty to the violation of probation." This poor choice of words could not convert a civil case into a criminal one or make proper an impermissible plea. It amounted to no more than an admission of violation within the context of Rule 4-242.
[3]  For provisions pertaining to the establishment and functions of the Maryland Judicial Conference, see Md.Rule 1226.
[4]  The small number of cases likely to be affected by what is now § 12-302(e) has been noted throughout the law's history. In 1978, after the measure's initial failure in the General Assembly, the Executive Secretary of the Maryland Judicial Conference observed that "[p]art of the problem ... [is] that we are dealing with a relatively small number of appeals." Memorandum of 11 August 1978 from the Executive Secretary to the Legislative Committee, at 5. That is, the legislature seemed reluctant to act because the probable workload relief for the Court of Special Appeals would be minimal. The Senate Judicial Proceedings Committee file on S.B. 617 (1978) contains notations to the same effect.
[5]  A violation hearing was held in July 1985. Probation was revoked and the five-year sentence imposed. For reasons not pertinent here, that judgment was reversed. Another hearing in December 1985 produced the same result. That judgment, too, was reversed. The hearing in the case now before us was held in September 1986.
[6]  The court in People v. Rodgers did acknowledge, however, that under the original sentence-credit statute, giving "credit for time spent in custody in any jail," the petitioner would not have been awarded credit for time spent at the halfway house. Id. 79 Cal. App.3d at 30, 144 Cal. Rptr. at 604, quoting 1971 Cal. Stat. ch. 1732, § 2, p. 3686.
[7]  Section 3.6(a) provides as follows:

Credit against the maximum term should be given to a defendant for all time spent in custody as a result of the criminal charge for which a prison sentence is imposed or as a result of the conduct on which such a charge is based. This should specifically include credit for time spent in custody prior to trial, during trial, pending sentence, pending the resolution of an appeal, and prior to arrival at the institution to which the defendant has been committed.
[8]  In Lock v. State, 609 P.2d 539, 545 (Alaska 1980), the Supreme Court of Alaska reached a contrary interpretation of § 3.6(a). There, the Court relied on the following language contained in comment b: "Credit should likewise be given against any prison term which is served after specified treatment has been provided. Credit in [this] context[s] would be required by section 3.6," id. at 545, and concluded that § 3.6(a) mandated that credit be awarded where an individual spent time at a drug treatment program as a condition of probation. Lock, however, ignores the fact that the "specified treatment" language in comment b refers to treatment given during the course of civil commitment, escape from which carries criminal penalties. Consequently, we find Lock unpersuasive.
[9]  Section 638C(a) deals only with public institutions. This is evidenced by the fact that the enumerated institutions are all modified by the adjectives "state," "county," or "city." Under the doctrine of ejusdem generis, we construe "other agency" as including only a public agency similar to the ones listed. See State v. 149 Slot Machines, 310 Md. 356, 363, 529 A.2d 817, 820 (1987).
[10]  Maus's arguments are based solely on the United States Constitution. He makes no claims under the Maryland Declaration of Rights.
[11]  Maus's equal protection claim was more of a passing reference than argument on the issue. See Maus's Br., pp. 24-25.
[12]  We note that the court did credit Maus with 25 months of actual jail and prison incarceration served by him in various contexts between his 1982 disposition hearing and the probation revocation hearing in September 1986.
[13]  Actually Wilkes poses two additional issues. The second has to do with whether the trial court abused its discretion in revoking his probation. Because we shall vacate the judgment of the trial court on other grounds, we shall not reach the second issue.
[14]  As we have noted in Part I of this opinion, Rule 4-242 is not applicable to revocation of probation proceedings. What Judge Rea meant was that a denial of the violations charged would be entered.
[15]  This panel is a group of lawyers assembled to assist people who are deemed ineligible for Public Defender services, but who would find it a hardship to pay customary fees for private counsel.
[16]  We observe that had Wilkes been asked, and had he indicated a desire for counsel, but lack of economic qualification for public defender representation, the court would have been required to make a further inquiry. The Public Defender is statutorily required to represent indigent defendants in revocation of probation proceedings, at least where revocation may result in incarceration. Md. Code Ann., (1986 Repl.Vol.) art. 27A, § 4(b)(4). If the Public Defender declines to act, the court may, under some circumstances, appoint counsel for the defendant. Id., § 6(f). Thus, when the Public Defender declines to represent the indigent defendant, "there is ... [a] clear duty imposed upon the court, in order to decide whether it should appoint counsel, ... to make its own independent determination whether a defendant is indigent and otherwise eligible to have counsel provided." Thompson v. State, 284 Md. 113, 129, 394 A.2d 1190, 1198 (1978). Failure to do so is reversible error. Id. at 130-131, 394 A.2d at 1198-1199. No such inquiry was made here, but given the court's failure to comply with Rule 4-215, we do not know whether the Public Defender's absence on 29 October was due to the fact that the Office declined to represent Wilkes or for some other reason.
[17]  There is another minor wrinkle in this case. On 19 February 1987, while Wilkes's case was pending in the Court of Special Appeals, Judge Ahalt reconsidered his reimposition of the ten-year sentence. He suspended the balance of the incarceration and placed Wilkes on what appears to be a new five year period of probation, subject to some new conditions. The fact that Wilkes is now on probation again does not, however, make his appeal moot. As in Kupfer v. State, 287 Md. 540, 414 A.2d 907 (1980), Wilkes is appealing the determination that he violated his probation. Moreover, the 1987 order may itself have been improper, since it appears to impose a new five year period of probation in addition to the probation time Wilkes had already served. This violates art. 27, §§ 641A and 642, since no restitution is involved here. Christian v. State, 62 Md. App. 296, 489 A.2d 64 (1985). See also State v. Oliver, 302 Md. 592, 490 A.2d 242 (1985).
