
    Argued and submitted March 30,
    the order on the petition of Tracee Shrewsbury is reversed; petition of Mollie Ann Russell is dismissed as moot May 5,
    reconsideration denied June 18,
    petition for review denied July 28, 1981 (291 Or 368)
    In the Matter of the Application of Tracee Shrewsbury, a Child. In the Matter of the Application of Tracee Shrewsbury for a Writ of Habeas Corpus. SHREWSBURY, Respondent, v. LARSON et al Appellants. In the Matter of Mollie Ann Russell, a Child. In the Matter of the Application of Mollie Ann Russell for a Writ of Habeas Corpus. RUSSELL, Respondent, v. BALL et al Appellants.
    
    (No. JC 67,629, CA A20307)
    (No. JC 63,468, CA A20309)
    (Cases Consolidated.)
    627 P2d 910
    
      Dave Frohnmayer, Attorney General, Salem, argued the cause for appellants. With him on the brief were John R. McCulloch, Jr., Solicitor General, William F. Gary, Deputy Solicitor General, James E. Mountain, Jr., Assistant Attorney General, and Virginia L. Linder, Assistant Attorney General, Salem.
    Jenny M. Cooke, Portland, argued the cause and filed the brief for respondents.
    Susan M. Svetkey, Julie H. McFarlane and Alan Baily, Portland, filed a brief amicus curiae for Juvenile Rights Project of Oregon Legal Services.
    Elizabeth Welch and Doblie, Francesconi & Welch, P.C., Portland, filed a brief amicus curiae for Rosemont School, Inc.
    Before Joseph, Chief Judge, and Buttler and Gillette, Judges.
    BUTTLER, J.
   BUTTLER, J.

In these two consolidated cases, which were brought as proceedings in habeas corpus, defendants appeal the trial court orders directing removal of the juvenile petitioners from Rosemont School (Rosemont) on the ground that the school is a "private institution operated as a training school for children requiring secure custody” and that, as such, placement by Children’s Services Division (CSD) in that school was not authorized by law. ORS 419.509a).

Defendants assign error to (1) the trial court’s ruling that the petitions sufficiently stated claims for habeas corpus relief; (2) the denial of the motions to quash the writs made on the ground that the court lacked jurisdiction over them because the parties were not properly served, and (3) the holding that Rosemont School is a "private institution operated as a training school for children requiring secure custody.” Before proceeding to a discussion of those questions, a brief summary of the juvenile court system is necessary.

THE JUVENILE COURT SYSTEM

A juvenile court is a court of general and equitable jurisdiction. ORS 419.474(1). The provisions relating to juvenile court are to be liberally construed

"(2) * * * to the end that a child coming within the jurisdiction of the court may receive such care, guidance and control, preferably in his own home, as will lead to the child’s welfare and the best interest of the public, and that when a child is removed from the control of his parents the court may secure for him care that best meets the needs of the child.” ORS 419.474(2).

The juvenile court may acquire jurisdiction over two categories of persons under 18: (1) those who have committed an act which if done by an adult would be a violation of federal, state or local law, ORS 419.476(l)(a), (whom we shall term law violators), and (2) non-law violators, which group includes those beyond the control of parents or guardians, those whose own welfare is endangered by their behavior or circumstances or who endanger others (so-called status offenders), those dependent on a child caring agency where planning is needed, runaways, those abandoned, neglected or abused by their parents or custodians, and those who have filed a petition for emancipation. ORS 419.476(l)(b) - (g).

Juvenile court jurisdiction may originate either by transfer of a case from another court, ORS 419.478, the taking of a child into temporary custody by a peace officer or CSD worker, ORS 419.573; 419.569, or by the filing of a petition by any person alleging jurisdiction in juvenile court. ORS 419.482(1) and (3). Proof of the court’s jurisdiction is by a preponderance of the evidence, except in a case where jurisdiction may result in commitment to a juvenile training school (that is, where the determination is that the juvenile is a law violator), when the proof must be beyond a reasonable doubt. ORS 419.500(1).

A juvenile court is given great flexibility in the different types of dispositions it may make of a child determined to be within its jurisdiction, depending on the best interests and welfare of the child. It may, among other things:

(1) Place the child on probation or under protective supervision and place legal custody with a relative or foster parent, or put the child in a child care center or youth center. The court may then impose restrictions on visitation by the parents or on the child’s associates and activities, and also impose consultation with juvenile counselors. The court may define the duration of this type of disposition or make it indefinite. ORS 419.507(1).

(2) Place the child in CSD’s legal custody for care, placement and supervision. ORS 419.507(2). CSD may place the child in a certified child care center. ORS 419.507(2)(a). The court, however, once the child is placed in the custody of CSD, may not thereafter make a commitment directly to any residential facility. ORS 419.507(2)(b). The court has continuing jurisdiction to protect the rights of the child or parents or guardians, ORS 419.507(2)(f), and retains wardship over the child, but CSD retains legal custody regardless of physical placement, ORS 419.507(7), and is the guardian of the child so long as CSD has legal custody. ORS 419.511(3). A commitment to CSD is for an indefinite term. ORS 419.511(1).

(3) With or without placing custody with CSD, place the child in a juvenile training school or a "private institution operated as a training school for children requiring secure custody,” but only if the child is within the court’s jurisdiction under ORS 419.476(l)(a), that is, if the child is a law violator. ORS 419.509(1). CSD may not make that kind of placement even when it has legal custody; only the comb may order it. CSD, however, may authorize the superintendent of the juvenile training school in which the child is placed by a court order to act as the child’s guardian. ORS 419.511(3). The term of commitment may not be longer than the maximum period of institutionalization authorized if the law violation had been committed by am adult or beyond the juvenile’s attaining the age of 21, ORS 419.511(1).

(4) Place the child for treatment in a hospital or suitable facility for examination or treatment by doctors in lieu of, or in addition to, the other options described above. ORS 419.511(2).

It is apparent that the legislature intended the court to have substantial flexibility in dealing with a child who has become a ward of the court. This flexibility relates not only to the original disposition of the child, but to the ongoing care and treatment through the court’s continuing jurisdiction. ORS 419.507(2)(f). Further, the law authorizes the corut to modify or set aside any order upon such notice and hearing as it may direct. ORS 419.529(1). When custody of a child has been placed with CSD, a detailed report to the court is required after six months, except when commitment has been made by the court directly to a juvenile training school. ORS 419.576(l)(a). Upon receiving the report, the court may hold a hearing to review the child’s condition and circumstances and to determine if the court should order any modifications in the care, placement and supervision of the child. ORS 419.576(4).

It is also apparent that the legislature intended that CSD have substantial flexibility. In addition to what is set forth above, when a child has been placed in a juvenile training school (i.e., Hillcrest or MacLaren), CSD may remove the child therefrom and place him or her on parole, after advising the committing court, and may place the child in a "suitable and desirable home” or facility. ORS 420.045(1). With the consent of the juvenile court, CSD may issue a final order discharging the child, ORS 420.045(2), but the child remains a ward of the court until jurisdiction is terminated. See ORS 419.531.

Although it is clear that the legislature intended the flexibility summarized above, the precise limits within the spectrum of permitted restraint of a juvenile status offender’s liberty is less than clear. We know that at one end of the spectrum is the minimum restraint of placing the child under protective supervision in the custody of a relative; at the other extreme, and beyond the authority of the court or CSD, is placement of a status offender in Hillcrest or MacLaren. A clue as to the reason for prohibiting that kind of placement is suggested by the Juvenile Code Committee’s commentary to the 1972 proposed revision of the juvenile statutes, but we find no clear answer as to how much restraint of the child’s freedom may be permitted short of prohibited placement in Hillcrest or MacLaren.

THESE PETITIONERS

Petitioners here are adjudicated juvenile status offenders, not law violators, who were committed by the court to the legal custody of CSD and placed in a residential care facility. The record tells us that Shrewsbury, age 16, was made a ward of the court on January 3, 1980, and placed in the custody of CSD, which placed her in the Cedar Hills Hospital for psychiatric treatment. In July, 1980, CSD transferred her to Clackamas House, a part of the Janis program. Clackamas House is one of three houses maintained by Janis for adolescents with a history of psychiatric hospitalization who are classified as mentally or emotionally disturbed. Initially, she was difficult to work with but, as time went on, she began to integrate well into the household. Clackamas House did not have locked doors, but allowed its residents to leave the facility after receiving permission to do so and after providing information on where they were going and when they would return. Shrewsbury frequently stayed out beyond the permitted times, as a result of which she was "grounded”; during the summer, she was "grounded” at one time for a period of four to six weeks. There were varying degrees of "grounding,” ranging from the requirement that she return earlier than otherwise might be required, to not being allowed to go out for a specified time. While at Clackamas House, Shrewsbury on one occasion took an overdose of drugs, which required treatment in an emergency room.

CSD was concerned that Shrewsbury could not successfully manage the Janis program, and therefore had her screened for placement at Rosemont School. The CSD caseworker thought that Rosemont could provide her with more supervision and that the individual and group counseling available there would provide a more effective treatment program to help Shrewsbury deal with her problems. Accordingly, petitioner Shrewsbury was placed in Rosemont in October, 1980.

Rosemont’s treatment program is highly individualized and is based on a "phasing system.” In the initial phase, the program is quite structured, involving daily evaluation of the children. Upon placement, each child is assessed, taking into consideration problems that were identified prior to coming into the program. From that assessment, goals are established as part of each child’s treatment program. The children participate in group therapy and, when feasible, there is an attempt to work with the children’s families. Supervision is provided 24 hours a day.

The school is located in a residential neighborhood of Portland. The backyard is fenced and a large hedge is around most of the property. The front and back doors of the school are kept locked for security purposes, and there is a night watchman to provide security for the building and to make sure the girls are not out of their rooms.

Under the "phasing system,” children are accompanied by staff personnel whenever they leave the facility during the first two phases. They are permitted to go on frequent outings to attend shows or to go shopping; their supervision during such times is minimal. When the children visit their homes, they do so without the accompaniment of a staff member, although a staff member takes them to and from their homes. In the later phases of the program, the children may go shopping or on walks without supervision. Petitioner Shrewsbury testified that she had "accomplished phase two,” and that she was pleased with the progress she was making; however, she wants to leave Rosemont.

All we know from the record with respect to petitioner Russell is that she is also 16 years old, was made a ward of the court on October 6, 1980, by reason of being beyond parental control, was committed to the custody of CSD and placed by CSD at Rosemont School.

A VAILABILITY OF HABEAS CORPUS

Each of these proceedings was commenced by the filing of a "Petition for Writ of Habeas Corpus,” each of which contained allegations conforming to the provisions of ORS 34.310 and 34.330. The petitions alleged the existence of the juvenile court orders adjudging them status offenders, and their commitment to the custody of CSD followed by their commitment to Rosemont. They alleged that Rosemont is "a private institution operated as a training school for children requiring secure custody,” which, it is alleged, makes that placement illegal and constitutes illegal confinement and restraint of petitioners. The petitions were filed, however, not as original actions in the circuit court, but in the juvenile court and have the same case numbers as those given the original juvenile court proceedings.

In each case, the petitions were presented to a judge of the Juvenile Department of the Circuit Court of Multnomah County who, based thereon, allowed the issuance of writs of habeas corpus, which were then issued by the clerk. ORS 34.370. Becáuse the juvenile court is a court of general and equitable jurisdiction, that judge had authority to authorize the issuance of the writs if the petitions were sufficient on their face. CSD contends that the petitions are not sufficient because they do not allege the lack of any alternative remedy and, further, that as a matter of law there is a readily available remedy through the continuing jurisdiction of the juvenile court, which precludes resort to the extraordinary writ of habeas corpus. The question, one of great general importance concerning minors who are subject to juvenile court jurisdiction, transcends the disposition of these cases.

Here, the legality of the underlying "confinement” of the petitioners is not questioned. They alleged in their petitions the existence of the orders finding them within the jurisdiction of the juvenile court as status offenders and their commitment to the custody of CSD "for care, placement and supervision for an indefinite period not to extend beyond” their attaining age 21. They do not contend that they may not be placed in any setting or facility which would necessarily "restrain” their freedom of movement. In fact, petitioner Shrewsbury alleged that she had been properly placed by CSD in the Janis group home, but had been removed from Janis and placed in Rosemont, an "illegal” placement, and that the transfer was accomplished without affording her due process of law. If the placement in Rosemont was illegal, the due process contention is superfluous and we do not understand petitioner Shrewsbury to contend she is entitled to a due process hearing prior to a transfer from one "proper” placement to another.

It appears, therefore, that the situation is one where each petitioner’s freedom has been restrained by the original court order, concededly valid, and somewhat further restrained by a custody commitment to CSD and, in the case of Shrewsbury, restrained even further, but within the flexible options available to CSD, by placement in Janis and finally restrained further yet by CSD’s allegedly exceeding its valid options by placing her in Rosemont, the claimed "imprisonment.” In some respects, the situation resembles that involved in Penrod/Brown v. Cupp, 283 Or 21, 581 P2d 934 (1978), where the petitioner Penrod was validly imprisoned in OSP, but contended that he had been unlawfully placed in segregation and isolation within the penitentiary, i.e., that he was unlawfully "imprisoned within the prison.” On his habeas corpus petition, the court held that the writ was available as a remedy to determine his further imprisonment or restraint within the prison.

The court in Penrod/Brown discussed the recent judicial extension of the availability of the writ to permit prisoners, validly imprisoned, to challenge illegal treatment within the penal institution as constituting an unlawful restraint of their liberty. The court posed the problem as being how far the use of that extraordinary remedy should be expanded. It said:

"The answer must be found in the nature of the claimed deprivation and the adequacy of the remedy otherwise available. A central characteristic of the writ, the main purpose achieved by the Habeas Corpus Act of 1679, is the speed with which it triggers a judicial inquiry. The asserted deprivations may range from serious claims of present or impending cruel and unusual punishment as in Bekins [v. Cupp, 274 Or 115, 545 P2d 861 (1976)], or infringements of religious freedom as in Newton [v. Cupp, 3 Or App 434, 474 P2d 532 (1970)], which if valid require urgency, to many other kinds of claims for which another remedy available to prisoners is adequate. For instance, given access to other remedies, habeas corpus normally should not be needed to challenge overcrowding, the quality of prison food, the opportunities for recreation or exercise, or similar conditions of imprisonment even when the challenge has merit. * * 283 Or at 27.

When the court summarized its conclusions (283 Or at 28), it was not made entirely clear whether, in the abstract, one claiming an unlawful further imprisonment or restraint, although validly in custody, needs to allege the need for immediate attention or the urgency of the harm to which the person claims to be exposed, and the practical inadequacy of an alternative remedy to meet the needs. When read in the context of the issues presented, we conclude that the court’s holding applies only to prison inmates validly incarcerated who claim "further 'imprisonment or restraint’ ” within the prison. However, the opinion, read as a whole, appears to support the conclusion that, as a general proposition, it is necessary in order to invoke habeas corpus to allege both the urgency of the harm and the lack, or inadequacy, of any alternative remedy — or at the least that there not be an adequate alternate remedy as a matter of law. See Mueller v. Cupp, 45 Or App 495, 499, 608 P2d 1203 (1980).

Here, petitioners do not allege any particular harm, much less the urgency of any harm. For example, neither alleges she is locked up in solitary confinement. The only specific allegation is that because of their placement in Rosemont they are commingled with children who have been adjudicated law violators. We have found nothing in the statutes prohibiting CSD from placing both kinds of offenders in the same facility, and no authority to that effect has been cited to us. (See n 7.)

Neither is there any allegation that petitioners have no alternative, readily available and adequate remedy. We conclude that they do, as a matter of law, have such a remedy by petition to the juvenile comí; which had, and has, continuing jurisdiction over petitioners’ wardship, ORS 419.507(2)(f), with authority to order CSD to remove them from Rosemont, either because the placement was not authorized by law (if that is the case), petitioner is being disciplined in a manner prohibited by CSD regulations, or because it is an inappropriate placement for either or both of petitioners. See State ex rel Juv. Dept. v. L., 24 Or App 257, 546 P2d 153, rev den (1976). We have no reason to believe that the juvenile court would not act speedily on such a petition. As we view that remedy, it is more adequate in the sense that it is more flexible than a writ of habeas corpus. Given this fact, we conclude that under Penrod/Brown the writ is unavailable.

There is another reason, based on public policy, which we conclude militates against the writ’s general availability to challenge the placement of children who are wards of the court. As pointed out earlier in this opinion, the legislature intended for the juvenile court and CSD to have substantial flexibility in the care, placement and supervision of children within the court’s jurisdiction. It also intended the juvenile court to have substantial authority in its continuing jurisdiction to determine, if called upon to do so, what is in the best interest and welfare of the child. To permit placements to be challenged by habeas corpus proceedings, which need not be filed in the juvenile court, by alleging that the child is being imprisoned unlawfully by having his or her liberty restrained by virtue of being placed in an authorized placement facility (such as a child care center, a group home or a foster home) over which CSD has supervisory authority would, it seems to us, deviate from the legislative scheme — and unnecessarily so. Availability of the writ to obtain release from placement in a facility over which neither CSD nor the juvenile court has supervisory authority (such as a county jail) is another matter and does not call for a decision here. See Peters v. Renfro, 43 Or App 411, 602 P2d 1137 (1979).

For the foregoing reasons, we conclude that the writ should not have been issued based upon the petitions in these cases. Therefore, unless the proceedings may be treated as applications to the juvenile cotut, qua juvenile court, in the exercise of its continuing jurisdiction under ORS 419.507(2)(f) and (7), the proceedings should have been dismissed.

It is clear from the trial court’s opinion that the only issue decided was whether the placement of petitioners in Rosemont was unlawful under ORS 419.509(1). It is not so clear from the transcript, opinion and order that the proceedings were treated strictly as habeas corpus proceedings rather than as hearings on petitions filed pursuant to the juvenile court’s continuing jurisdiction over its wards. The order does recite that the matter came on for hearing on a writ of habeas corpus, but the dispositive portion of the order is consistent with an ordinary juvenile court order: each petitioner is continued as a ward of the court, is continued in CSD custody for care, placement and supervision, and CSD is ordered to remove each petitioner from Rosemont within 72 hours.

Given this state of the record, the importance of the question petitioners seek to have resolved and the probable desirability of legislative attention to the underlying problem, we proceed to a consideration on the merits as if the proceedings below were conducted pursuant to the continuing jurisdiction of the juvenile court.

ROSEMONT AS AN A UTHORIZED PLACEMENT

It is clear enough that the law prohibits placement of status offenders (such as petitioners) in a juvenile training school, which ORS 420.005(3) defines by saying it "* * * means Hillcrest School of Oregon, the MacLaren School for Boys and any other school established by law for similar purposes, and includes the other camps and programs maintained under this chapter.” It seems clear that Rosemont is not within that definition, unless it can be said that such "other school” includes a school which is merely licensed by the state but not specifically established by legislation. We do not accept that proposition.

It is also clear that petitioners may not be placed in a "private institution operated as a training school for children requiring secure custody.” ORS 419.509(1). There appears to be no definition, other than the descriptive words themselves, of that kind of school. Presumably it means the same kind of school as Hillcrest or MacLaren, but operated privately and licensed, as such, by the state, whereas "any other school established by law,” as used in ORS 420.005, means such school authorized by the legislature and operated by the state. Under that interpretation, then, our inquiry is limited to whether a placement facility is authorized by the legislature and operated by the state (Rosemont is not), or whether the facility is licensed by the state (and, as discussed below, certified by CSD) and, if so, the placement facility’s authority under the applicable statutes. Once that inquiry is resolved, the status of the facility as a lawful or unlawful placement is determined.

Any other interpretation would require a factual determination in each case where placement is put in question to determine how the facility is operated, notwithstanding its licensed authority. We do not believe the legislature intended for the courts to engage in a factual determination on a case-by-case basis of the status of a placement facility as being permissible or not. To construe the statutory language to require such factual determination in each case could, and probably would, result in inconsistent determinations of the status of the same facility, which is not an acceptable solution.

Having concluded that the legislature intended that the inquiry be limited, we find no authority for the licensing of a "private institution operated as a training school for children requiring secure custody.” Although the record here is meager, there is testimony, admitted without objection, that Rosemont is licensed under the "child care statutes” as a "residential treatment center” and is "supervised” or "inspected” by CSD.

Under ORS Chapter 443 certain "residential facilities” may be licensed. A "residential treatment facility,” which is included within the term "residential facility” (ORS 443.400(3)), is defined by ORS 443.400(7) and (10):

"(7) 'Residential treatment facility’ means a facility that provides, for six or more mentally, emotionally or behaviorally disturbed individuals, residential care and treatment in one or more buildings on contiguous properties.
* * * *
"(10) 'Treatment’ means a planned, individualized program of medical, psychological or rehabilitative procedures, experiences and activities designed to relieve or minimize mental, emotional or physical symptoms or social, educational or vocational disabilities resulting from or related to the mental ór emotional disturbance or physical handicap.”

ORS 443.405 excludes from the definition of "residential facility,” so far as relevant:

(1) a residential school, and

(2) juvenile training schools as defined in ORS 420.005.

Residential school is not defined. However, in the context of Chapter 443 it appears to mean a private boarding school that is not intended to do anything other than provide a formal education. The exclusion of juvenile training schools as defined in ORS 420.005 clearly excludes any licensing requirement for Hillcrest and MacLaren and also for "any other school established by law for similar purposes.”

We find no provision for licensing, or excluding from licensing requirements, a "private institution operated as a training school for children requiring secure custody.” That language in ORS 419.509(1) seems to anticipate that the legislature might authorize licensing such an institution in the future, in which case it would be treated, for placement purposes, the same as Hillcrest and MacLaren. As of now, we find no authority for such an institution to exist.

As stated above, the record here indicates that Rosemont is licensed as a "residential treatment center.” CSD is authorized to place juveniles within its jurisdiction in a residential care facility if it meets the requirements of ORS 418.215, which includes certification by CSD and licensing under ORS 443.400 to 443.455, if it serves six or more residents. Rosemont is such a facility, being licensed to provide residential treatment for 56 girls, and, as such, it is subject to supervision (ORS 418.250) and inspection (ORS 418.255) by CSD, and CSD is mandated by ORS 418.260 to investigate any reports of abuses, dereliction or deficiencies and to take such action as the matter may require.

As a matter of law, then, it appears that Rosemont is a residential child care treatment facility in which CSD is authorized by law to place juveniles committed to its custody. There is nothing in any of the statutes which authorizes any facility licensed as a "residential treatment facility” to operate as a "training school for children requiring secure custody,” and there is nothing in this record to support the conclusion that Rosemont is authorizedto operate for that class of children. The most that can be said is that there is some evidence that there may be some juvenile law violators among the residents; however, not all juvenile law violators require secure custody. If the facility is operating in a manner inconsistent with, or outside of, its license, its CSD certification or CSD regulations, CSD has a duty to put a stop to it. CSD has substantial authority, including authority to suspend or revoke its certification of the facility, ORS 418.260, after which it must terminate all payments to the facility (OAR 412-24-015(7)), and it may remove the children placed there. If CSD refuses to recognize abuses, the juvenile court may direct removal of the juvenile from the facility. ORS 419.507(2)(f).

Accordingly, treating these cases as juvenile court proceedings, we conclude that as a matter of law Rosemont, as a licensed and CSD certified residential treatment center, is a facility duly authorized as one in which juvenile status offenders committed to CSD’s jurisdiction may be placed. Whether it is an appropriate placement for either of the petitioners, or whether it is operating beyond the authority of its charter, its license, its certification or CSD regulations are questions not before us.

After these cases were submitted and this opinion prepared, petitioner Russell was removed from Rosemont by CSD. Accordingly, her petition (CA A20309) is dismissed as moot.

The order on the petition of Tracee Shrewsbury (CA A20307) is reversed. 
      
       OKS 419.509(1) provides:
      "(1) A child placed in the legal custody of the Children’s Services Division shall be placed in a juvenile training school or in a private institution operated as a training school for children requiring secure custody in the following cases and no other:
      "(a) The child is found to be within the jurisdiction of the juvenile court by reason of a ground set forth in paragraph (a) of subsection (1) of ORS 419.476; and
      "(b) The juvenile court having jurisdiction so orders.”
     
      
       Also, the juvenile may not be placed in the Oregon State Penitentiary, the Oregon State Correctional Institution or the Oregon Women’s Correctional Center. ORS 419.507(2)(b).
     
      
       ORS 419.507(2)(f) provides:
      "(2) Place the child in the legal custody of the Children’s Services Division for care, placement and supervision.
      * * * *
      "(f) Commitment of a child to the Children’s Services Division does not terminate the court’s continuing jurisdiction to protect the rights of the child or his parents or guardians.”
      ORS 419.507(7) provides:
      "(7) The juvenile court shall retain wardship and the Children’s Services Division shall retain legal custody of the child committed to it regardless of the physical placement of the child by the Children’s Services Division.”
     
      
       Originally the statute allowed commitment to MacLaren School for Boys or Hillcrest School of Oregon of a juvenile falling within any of four categories: (1) law violators, (2) those beyond the control of their parents or custodians, (3) those whose behavior or condition endangered their own welfare or that of others and (4) persistent runaways. Or Laws 1959, ch 432, § 18. In 1963, the term "condition” was deleted from the third category. Or Laws 1963, ch 344, § 1. In 1971, the fourth category, persistent runaways, was deleted from the statute. Or Laws 1971, ch 105, § 1. In 1975, the second and third categories were eliminated. Or Laws 1975, ch 718, § 3. Accordingly, since 1975 the only children who may be sent to a juvenile training school are law violators.
     
      
       ORS 419.507(2)(f) provides:
      "(2) Place the child in the legal custody of the Children’s Services Division for care, placement and supervision.
      «‡ sfc if: %
      "(f) Commitment of a child to the Children’s Services Division does not terminate the court’s continuing jurisdiction to protect the rights of the child or his parents or guardians.”
     
      
       ORS 419.529(1) provides:
      "(1) Except as provided in this section, the court may modify or set aside any order made by it upon such notice and with such hearing as the court may direct.”
     
      
       OES 419.509 was amended in 1975 to restrict placements to juvenile training schools. (See n 4, supra.) The committee’s commentary with respect to that matter was:
      "Delinquent act cases are the only instances where the child has done an act which is against the public. Juvenile training schools are institutions which involve the possible use of secure custody for the protection of the public, while providing treatment to the child. The committee found little reason to believe that placement in a training school is an effective deterrent in such matters as failure to obey one’s parents, or that it is an appropriate resource for assisting the child involved. Furthermore, the lack of restriction on the type of cases served has resulted in such a diverse population in the juvenile training school that it has not been possible to develop a specialized intensive program to treat the child who is in serious danger of going to the criminal system. Removal of a child from his community and placement in secure custody institutions should be used sparingly and only where the public protection requires it and the child is in need of intensive care. Community-based youth care centers are a far better alternative where a residential placement other than the family home is indicated for children in need of supervision.” Final Draft and Report, October, 1972, Proposed Revision Laws Relating to Children, Legislative Interim, Juvenile Code Committee, § 47 at 63, 64.
      That commentary suggests both that not all juvenile law violators need to be placed in Hillcrest or MacLaren (secure custody) and that placement in a residential care center is not to be equated with "secure custody.”
     
      
       ORS 34.310 provides:
      "The writ of habeas corpus ad subjiciendum is the writ designated in ORS 34.310 to 34.730, and every other writ of habeas corpus is abolished. Every person imprisoned or otherwise restrained of his liberty, within this state, except in the cases specified in ORS 34.330, may prosecute a writ of habeas corpus to inquire into the cause of such imprisonment or restraint, and if illegal, to be delivered therefrom.”
      ORS 34.330 provides:
      "The following persons shall not be allowed to prosecute the writ:
      "(1) Persons imprisoned or restrained by virtue of process issued by a court of the United States, or a judge, commissioner or other officer thereof, in cases where such courts, or judges or officers thereof, have exclusive jurisdiction under the laws of the United States, or have acquired exclusive jurisdiction by the commencement of actions, suits or other proceedings in such court, or before such commissioner or other officer.
      "(2) Persons imprisoned or restrained by virtue of the judgment or decree of a competent tribunal of civil or criminal jurisdiction, or by virtue of an execution issued upon such judgment or decree.
      "(3) Except as provided in ORS 138.560, persons eligible to obtain post-conviction relief pursuant to ORS 138.510 to 138.680.”
     
      
       "In summary, we conclude that the writ remains available to bring before a court the two kinds of cases we have described: (1) When a petition makes allegations which, if true, show that the prisoner, though validly in custody, is subjected to a further 'imprisonment or restraint’ of his person that would be unlawful if not justified to the court, and (2) when a petition alleges other deprivations of a prisoner’s legal rights of a kind which, if true, would require immediate judicial scrutiny, if it also appears to the court that no other timely remedy is available to the prisoner. It is neither possible nor proper to list hypothetical claims of this second kind in advance of their arising, but we emphasize the two essential elements that must coincide to make the writ of habeas corpus a proper instrument of judicial inquiry: The need for immediate attention, if this appears from the urgency of the harm to which the prisoner claims to be exposed or if it is found to be required as a matter of constitutional law, and the practical inadequacy of an alternative remedy to meet this need. Of course, it does not follow that upon issuance of the writ the prisoner will in fact be entitled to relief. We hold only that if these two elements appear from the petition, habeas corpus is not unavailable as a matter of law. In such a case, the circuit court will properly dismiss the petition if, but only if, the court identifies another timely remedy that actually is available to petitioner, or when the court finds that the alleged deprivations, even if arguably unlawful, do not require immediate judicial intervention pending resort to the available remedy.” 283 Or at 28.
     
      
       OAK 412-24-020(3) provides:
      "(3) In disciplining children, employes and volunteers shall not use harsh punishment. Harsh means spanking, belting, physical/mental abuse, acts designed to humiliate, degrade, or undermine a child’s self-respect, punishment in the presence of a group, deprivation of parental visits, or placing the child in lock-up for punishment.”
     
      
       Because of our conclusion that the writs ought not to have been issued, we need not decide whether personal service on the Attorney General was necessary to obtain jurisdiction in these proceedings over CSD and the caseworkers. See ORCP 7D(3)(c). Petitioners’ contention that any defect in service was waived by the defendants’ participating in the proceedings after their motion was denied is not well taken if the defect was jurisdictional. ORCP 21G(1).
     
      
      
         The petitioners and the court (but not CSD) agreed that the disposition of the Shrewsbury case would dispose of the Russell case because the proceedings were treated as intended to determine only the lawfulness of placement of both petitioners in Rosemont. CSD put on no evidence with respect to Russell.
     
      
       Originally the statute referred to placement "in an institution, such as MacLaren School for Boys or Hillcrest School of Oregon, operated as a training school for children requiring secure custody.” Or Laws 1959, ch 432, § 18. In 1963, the phrase became "in an institution operated as a training school for children requiring secure custody or in the MacLaren School for Boys or the Hillcrest School of Oregon.” Or Laws 1963, ch 344, § 1. In 1969, the provision referred to placement "in the legal custody of the Corrections Division of the Oregon State Board of Control or in a private institution operated as a training school for children requiring secure custody.” Or Laws 1969, ch 679, § 2. In 1971, "Corrections Division” became "Children’s Services Division.” Or Laws 1971, ch 401, § 92. The phrase was amended in 1971 to refer to placement "in a juvenile training school or in a private institution operated as a training school for children requiring secure custody,” which is the present wording. Or Laws 1971, ch 698, § 3.
     
      
       That section also requires that the child-caring agency be incorporated, and ORS 418.220 requires that the corporate charter be approved by CSD.
     
      
       The term “secure custody” is not defined in the statutes. It appears most frequently in those statutes which relate to detentions prior to disposition. For example, "detention” or "detention facility” is defined by ORS 419.472(4) as:
      "(4) "Detention’ or 'detention facility’ means a facility suitable for the safekeeping of a child who is taken into temporary custody pending investigation and disposition where the circumstances are such that the child must be kept in secure custody.”
      ORS 419.575(4) requires that juvenile detention facilities, including jails or other lockups where juveniles are detained, be inspected in accordance with other statutory standards and the Corrections Division inspection standards set forth in ORS 169.005 to 169.690. These provisions suggest that 'secure custody1 involves custody in the nature of a jail or lockup confinement, not the kind of restraint imposed upon one by placement in a residential treatment facility where, necessarily, emotionally disturbed children might not be permitted to leave at will.
     
      
       Because we view the question, as being one of law, we have not discussed the evidence on which petitioners rely to show that Rosemont may be considered as "a private institution operated as a training school for children requiring secure custody.” ORS 419.509(1). We have noted, supra, that there is no evidence that Rosemont is operated for that class of children or that it is authorized to do so.
     