> For the complete documentation index, see [llms.txt](https://comaqa.gitbook.io/java-automation/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://comaqa.gitbook.io/java-automation/stil-napisaniya-koda/perenosy-v-obyavlenii-metodov.md).

# Переносы в объявлении методов

Рассмотрим два примера переноса строк в определении метода. Первый использует соглашения. Во втором использование соглашений привело бы к тому, что вторая и третья строка были бы слишком сдвинуты вправо, поэтому используется только отступ в 8 пробелов.

```
// СОГЛАШЕНИЕ ПО ОТСТУПАМ

someMethod(int anArg, Object anotherArg, String yetAnotherArg,
            Object andStillAnother) {
    ...
}

// ДЕЛАЙТЕ ОТСТУП В 8 СИМВОЛОВ ДЛЯ ИЗБЕЖАНИЯ ГЛУБОКОЙ ВЛОЖЕННОСТИ
private static synchronized horkingLongMethodName(int anArg,
        Object anotherArg, String yetAnotherArg,
        Object andStillAnother) {
    ...
}
```
